001: /*
002: *
003: * Copyright (c) 2004 SourceTap - www.sourcetap.com
004: *
005: * The contents of this file are subject to the SourceTap Public License
006: * ("License"); You may not use this file except in compliance with the
007: * License. You may obtain a copy of the License at http://www.sourcetap.com/license.htm
008: * Software distributed under the License is distributed on an "AS IS" basis,
009: * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
010: * the specific language governing rights and limitations under the License.
011: *
012: * The above copyright notice and this permission notice shall be included
013: * in all copies or substantial portions of the Software.
014: *
015: */
016:
017: package com.sourcetap.sfa.security;
018:
019: /** used to map linkage between entityAccess and application tables
020: * Entity Access for some tables (Accounts/Deals) is set explicitly
021: * Other tables (contacts) are granted implicit access based on the access granted to parent rows (Accounts)
022: */
023: public class SecurityLinkInfo {
024: public String entityName = null;
025: public String attributeName = null;
026: public boolean createEntityAccess = false;
027:
028: public SecurityLinkInfo() {
029: }
030:
031: public SecurityLinkInfo(String entityName_, String attributeName_) {
032: entityName = entityName_;
033: attributeName = attributeName_;
034: }
035:
036: public SecurityLinkInfo(String entityName_, String attributeName_,
037: boolean createEntityAccess_) {
038: entityName = entityName_;
039: attributeName = attributeName_;
040: createEntityAccess = createEntityAccess_;
041: }
042:
043: /**
044: * DOCUMENT ME!
045: *
046: * @return
047: */
048: public String getEntityName() {
049: return entityName;
050: }
051:
052: /**
053: * DOCUMENT ME!
054: *
055: * @return
056: */
057: public String getAttributeName() {
058: return attributeName;
059: }
060:
061: /**
062: * DOCUMENT ME!
063: *
064: * @return
065: */
066: public boolean getCreateEntityAccess() {
067: return createEntityAccess;
068: }
069:
070: /**
071: * DOCUMENT ME!
072: *
073: * @param entityName_
074: */
075: public void setEntityName(String entityName_) {
076: entityName = entityName_;
077: }
078:
079: /**
080: * DOCUMENT ME!
081: *
082: * @param attrbuteName_
083: */
084: public void setAttributeName(String attrbuteName_) {
085: attributeName = attrbuteName_;
086: }
087:
088: /**
089: * DOCUMENT ME!
090: *
091: * @param createEntityAccess_
092: */
093: public void setCreateEntityAccess(boolean createEntityAccess_) {
094: createEntityAccess = createEntityAccess_;
095: }
096:
097: /**
098: * DOCUMENT ME!
099: *
100: * @return
101: */
102: public String toString() {
103: return entityName + "." + attributeName;
104: }
105: }
|