| Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
| ACLEntry |
|
| 1.0;1 |
| 1 | 0 | /** |
| 2 | * 2010, Digitalis Informatica. All rights reserved. Distribuicao e Gestao de Informatica, Lda. Estrada de Paco de Arcos | |
| 3 | * num.9 - Piso -1 2780-666 Paco de Arcos Telefone: (351) 21 4408990 Fax: (351) 21 4408999 http://www.digitalis.pt | |
| 4 | */ | |
| 5 | ||
| 6 | package pt.digitalis.dif.utils.extensions.cms; | |
| 7 | ||
| 8 | /** | |
| 9 | * An ACL (Access control list) item definition for content nodes and items | |
| 10 | * | |
| 11 | * @author Pedro Viegas <a href="mailto:pviegas@digitalis.pt">pviegas@digitalis.pt</a><br/> | |
| 12 | * @created 2010/10/06 | |
| 13 | */ | |
| 14 | 0 | public class ACLEntry { |
| 15 | ||
| 16 | /** the group ID */ | |
| 17 | private String groupID; | |
| 18 | ||
| 19 | /** the user ID */ | |
| 20 | private String userID; | |
| 21 | ||
| 22 | /** | |
| 23 | * Inspector for the 'groupID' attribute. | |
| 24 | * | |
| 25 | * @return the groupID value | |
| 26 | */ | |
| 27 | public String getGroupID() | |
| 28 | { | |
| 29 | 0 | return groupID; |
| 30 | } | |
| 31 | ||
| 32 | /** | |
| 33 | * Inspector for the 'userID' attribute. | |
| 34 | * | |
| 35 | * @return the userID value | |
| 36 | */ | |
| 37 | public String getUserID() | |
| 38 | { | |
| 39 | 0 | return userID; |
| 40 | } | |
| 41 | ||
| 42 | /** | |
| 43 | * @return T if the current ACL entry defines a group access | |
| 44 | */ | |
| 45 | public boolean isGroupEntry() | |
| 46 | { | |
| 47 | 0 | return groupID != null; |
| 48 | } | |
| 49 | ||
| 50 | /** | |
| 51 | * @return T if the current ACL entry defines a user access | |
| 52 | */ | |
| 53 | public boolean isUserEntry() | |
| 54 | { | |
| 55 | 0 | return userID != null; |
| 56 | } | |
| 57 | ||
| 58 | /** | |
| 59 | * Modifier for the 'groupID' attribute. | |
| 60 | * | |
| 61 | * @param groupID | |
| 62 | * the new groupID value to set | |
| 63 | */ | |
| 64 | public void setGroupID(String groupID) | |
| 65 | { | |
| 66 | 0 | this.groupID = groupID; |
| 67 | 0 | } |
| 68 | ||
| 69 | /** | |
| 70 | * Modifier for the 'userID' attribute. | |
| 71 | * | |
| 72 | * @param userID | |
| 73 | * the new userID value to set | |
| 74 | */ | |
| 75 | public void setUserID(String userID) | |
| 76 | { | |
| 77 | 0 | this.userID = userID; |
| 78 | 0 | } |
| 79 | } |