Statistics
| Branch: | Tag: | Revision:

root / src / gr / ebs / gss / server / domain / dto / UserClassDTO.java @ b7b8c586

History | View | Annotate | Download (2.4 kB)

1
/*
2
 * Copyright 2007, 2008, 2009 Electronic Business Systems Ltd.
3
 *
4
 * This file is part of GSS.
5
 *
6
 * GSS is free software: you can redistribute it and/or modify
7
 * it under the terms of the GNU General Public License as published by
8
 * the Free Software Foundation, either version 3 of the License, or
9
 * (at your option) any later version.
10
 *
11
 * GSS is distributed in the hope that it will be useful,
12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
 * GNU General Public License for more details.
15
 *
16
 * You should have received a copy of the GNU General Public License
17
 * along with GSS.  If not, see <http://www.gnu.org/licenses/>.
18
 */
19
package gr.ebs.gss.server.domain.dto;
20

    
21
import java.io.Serializable;
22
import java.util.ArrayList;
23
import java.util.List;
24

    
25
/**
26
 * A group of users with common attributes.
27
 *
28
 * @author droutsis
29
 */
30
public class UserClassDTO implements Serializable {
31

    
32
        /**
33
         * The serial version UID of the class.
34
         */
35
        private static final long serialVersionUID = 1L;
36

    
37
        /**
38
         * The persistence ID of the object.
39
         */
40
        private Long id;
41

    
42
        /**
43
         * A name for this class.
44
         */
45
        private String name;
46

    
47
        /**
48
         * The disk quota of this user class.
49
         */
50
        private long quota;
51

    
52
        /**
53
         * The users belonging to this class
54
         *
55
         */
56
        private List<UserDTO> users = new ArrayList<UserDTO>();
57

    
58
        @Override
59
        public String toString() {
60
                return name;
61
        }
62

    
63
        /**
64
         * Retrieve the id.
65
         *
66
         * @return the id
67
         */
68
        public Long getId() {
69
                return id;
70
        }
71

    
72
        /**
73
         * Modify the id.
74
         *
75
         * @param newId the id to set
76
         */
77
        public void setId(final Long newId) {
78
                id = newId;
79
        }
80

    
81
        /**
82
         * Retrieve the name.
83
         *
84
         * @return the name
85
         */
86
        public String getName() {
87
                return name;
88
        }
89

    
90
        /**
91
         * Modify the name.
92
         *
93
         * @param newName the name to set
94
         */
95
        public void setName(final String newName) {
96
                name = newName;
97
        }
98

    
99
        /**
100
         * Retrieve the quota.
101
         *
102
         * @return the quota
103
         */
104
        public long getQuota() {
105
                return quota;
106
        }
107

    
108
        /**
109
         * Modify the quota.
110
         *
111
         * @param newQuota the quota to set
112
         */
113
        public void setQuota(final long newQuota) {
114
                quota = newQuota;
115
        }
116

    
117
        /**
118
         * Retrieve the users.
119
         *
120
         * @return the users
121
         */
122
        public List<UserDTO> getUsers() {
123
                return users;
124
        }
125

    
126
        /**
127
         * Modify the users.
128
         *
129
         * @param newUsers the users to set
130
         */
131
        public void setUsers(final List<UserDTO> newUsers) {
132
                users = newUsers;
133
        }
134
}