blob: b46ed125a0faf0016598eea75f74f835ef1f2013 (
plain) (
blame)
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
|
/*******************************************************************************
* Copyright (c) 2011, 2012 Wind River Systems, Inc. and others. All rights reserved.
* This program and the accompanying materials are made available under the terms
* of the Eclipse Public License v1.0 which accompanies this distribution, and is
* available at http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Wind River Systems - initial API and implementation
* William Chen (Wind River) - [352302]Opening a file in an editor depending on
* the client's permissions.
*******************************************************************************/
package org.eclipse.tcf.te.tcf.filesystem.core.internal;
/**
* The data model of a user account.
*/
public class UserAccount {
// The user's id.
private int uid;
// The user's group id.
private int gid;
// The user's effective id.
private int euid;
// The user's effective group id.
private int egid;
// The user's home directory.
private String home;
/**
* Create a user account with given data.
*
* @param uid
* The user's id
* @param gid
* The user's group id
* @param euid
* The user's effective id.
* @param egid
* The user's effective group id.
* @param home
* The user's home directory.
*/
public UserAccount(int uid, int gid, int euid, int egid, String home) {
this.uid = uid;
this.gid = gid;
this.euid = euid;
this.egid = egid;
this.home = home;
}
/**
* Get the user's id.
*
* @return The user's id.
*/
public int getUID() {
return uid;
}
/**
* Get the user's group id.
*
* @return The user's group id.
*/
public int getGID() {
return gid;
}
/**
* Get the user's effective id.
*
* @return The user's effective id.
*/
public int getEUID() {
return euid;
}
/**
* Get the user's effective group id.
*
* @return The user's effective group id.
*/
public int getEGID() {
return egid;
}
/**
* Get the user's home directory.
*
* @return The user's home directory.
*/
public String getHome() {
return home;
}
}
|