arlut.csd.ganymede
Class permCustom

java.lang.Object
  |
  +--arlut.csd.ganymede.DBObject
        |
        +--arlut.csd.ganymede.DBEditObject
              |
              +--arlut.csd.ganymede.permCustom
All Implemented Interfaces:
db_object, FieldType, ObjectStatus, java.rmi.Remote, SchemaConstants

public class permCustom
extends DBEditObject
implements SchemaConstants

This file is a management class for Role records in Ganymede.


Field Summary
 
Fields inherited from class arlut.csd.ganymede.DBEditObject
ADDELEMENT, ADDELEMENTS, debug, DELELEMENT, DELELEMENTS, deleting, editset, FIRSTOP, LASTOP, maxDate, minDate, original, SETELEMENT, SETPASSAPACHEMD5, SETPASSCRYPT, SETPASSMD5, SETPASSPLAIN, SETPASSWINHASHES, SETVAL, status, stored
 
Fields inherited from class arlut.csd.ganymede.DBObject
debugEmit, fieldAry, gSession, myInvid, next, objectBase, permCacheAry, shadowObject
 
Fields inherited from interface arlut.csd.ganymede.SchemaConstants
BackLinksField, ContainerField, CreationDateField, CreatorField, EventBase, EventDescription, EventExternalMail, EventMailBoolean, EventMailOwners, EventMailToSelf, EventName, EventToken, ExpirationField, FinalBase, FinalSystemField, ModificationDateField, ModifierField, NotesField, ObjectEventBase, ObjectEventDescription, ObjectEventExternalMail, ObjectEventMailOwners, ObjectEventMailToSelf, ObjectEventName, ObjectEventObjectName, ObjectEventObjectType, ObjectEventToken, OwnerBase, OwnerCcAdmins, OwnerExternalMail, OwnerListField, OwnerMembersField, OwnerNameField, OwnerObjectsOwned, OwnerSupergash, PersonaAdminConsole, PersonaAdminPower, PersonaAssocUser, PersonaBase, PersonaGroupsField, PersonaLabelField, PersonaMailAddr, PersonaMonitorObj, PersonaNameField, PersonaPasswordField, PersonaPrivs, PersonaSupergashObj, RemovalField, RoleBase, RoleDefaultMatrix, RoleDefaultObj, RoleDelegatable, RoleMatrix, RoleName, RolePersonae, TaskBase, TaskClass, TaskName, TaskOptionStrings, TaskPeriodAnchor, TaskPeriodCount, TaskPeriodUnit, TaskRunOnCommit, TaskRunPeriodically, UserAdminPersonae, UserBase, UserPassword, UserUserName
 
Fields inherited from interface arlut.csd.ganymede.ObjectStatus
CREATING, DELETING, DROPPING, EDITING
 
Fields inherited from interface arlut.csd.ganymede.FieldType
BOOLEAN, DATE, FIRSTFIELD, FLOAT, INVID, IP, LASTFIELD, NUMERIC, PASSWORD, PERMISSIONMATRIX, STRING
 
Constructor Summary
permCustom(arlut.csd.ganymede.DBObjectBase objectBase)
          Customization Constructor
permCustom(arlut.csd.ganymede.DBObjectBase objectBase, arlut.csd.ganymede.Invid invid, arlut.csd.ganymede.DBEditSet editset)
          Create new object constructor
permCustom(arlut.csd.ganymede.DBObject original, arlut.csd.ganymede.DBEditSet editset)
          Check-out constructor, used by DBObject.createShadow() to pull out an object for editing.
 
Method Summary
 boolean canSeeField(arlut.csd.ganymede.DBSession session, arlut.csd.ganymede.DBField field)
          Customization method to verify whether the user should be able to see a specific field in a given object.
 boolean instantiateNewField(short fieldID)
          This method provides a hook that can be used to indicate whether a field that is defined in this object's field dictionary should be newly instantiated in this particular object.
 
Methods inherited from class arlut.csd.ganymede.DBEditObject
anonymousLinkOK, anonymousLinkOK, anonymousLinkOK, anonymousUnlinkOK, anonymousUnlinkOK, anonymousUnlinkOK, canBeInactivated, canClone, canCloneField, canCreate, canInactivate, canRead, canRemove, canWrite, checkNewField, checkpoint, choiceListHasExceptions, cloneFromObject, commitPhase1, commitPhase2, consistencyCheck, createNewEmbeddedObject, diff, excludeSelected, fieldRequired, finalizeAddElement, finalizeAddElements, finalizeDeleteElement, finalizeDeleteElements, finalizeInactivate, finalizeReactivate, finalizeRemove, finalizeSetElement, finalizeSetValue, getEditSet, getEmailTargets, getLabel, getLabelHook, getOriginal, getSession, getStatus, getVirtualValue, grantOwnership, hasEmailTarget, inactivate, initializeNewObject, internalSession, isCommitting, isDateLimited, isDeleting, isFloatLimited, isIntLimited, isIPv6OK, isStored, maxDate, maxFloat, maxInt, minDate, minFloat, minInt, mustChoose, obtainChoiceList, obtainChoicesKey, permExpand, permExpand, permOverride, permOverride, reactivate, release, remove, rollback, setCommitting, setDebug, setFieldValue, setFieldValueLocal, setStatus, useLabelHook, verifyNewValue, virtualizeField, wizardHook
 
Methods inherited from class arlut.csd.ganymede.DBObject
canInactivate, checkRequiredFields, clearField, clearFieldPerm, clearShadow, createShadow, emit, emitXML, equals, exportFields, findField, getASymmetricTargets, getBackLinks, getBase, getContainingLabel, getEmailTargets, getExpirationDate, getField, getField, getFieldDef, getFieldId, getFieldInfoVector, getFieldName, getFieldPerm, getFieldValue, getFieldValueLocal, getFieldValues, getFieldValuesLocal, getFieldVect, getFieldVector, getGSession, getID, getInvid, getLabelField, getLabelFieldID, getPrintString, getRemovalDate, getSummaryDescription, getTypeDesc, getTypeID, getTypeName, hasEmailTarget, hashCode, isEmbedded, isInactivated, isSet, isValid, listFields, lookupLabel, print, print, receive, replaceField, retrieveField, saveField, setBackPointers, toString, unsetBackPointers, updateBaseRefs, willBeRemoved, willExpire
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

permCustom

public permCustom(arlut.csd.ganymede.DBObjectBase objectBase)
           throws java.rmi.RemoteException
Customization Constructor


permCustom

public permCustom(arlut.csd.ganymede.DBObjectBase objectBase,
                  arlut.csd.ganymede.Invid invid,
                  arlut.csd.ganymede.DBEditSet editset)
           throws java.rmi.RemoteException
Create new object constructor


permCustom

public permCustom(arlut.csd.ganymede.DBObject original,
                  arlut.csd.ganymede.DBEditSet editset)
           throws java.rmi.RemoteException
Check-out constructor, used by DBObject.createShadow() to pull out an object for editing.

Method Detail

instantiateNewField

public boolean instantiateNewField(short fieldID)
This method provides a hook that can be used to indicate whether a field that is defined in this object's field dictionary should be newly instantiated in this particular object. This method does not affect those fields which are actually present in the object's record in the DBStore. What this method allows you to do is have a subclass decide whether it wants to instantiate a potential field (one that is declared in the field dictionary for this object, but which doesn't happen to be presently defined in this object) in this particular object. A concrete example will help here. The Permissions Object type (base number SchemaConstants.PermBase) holds a permission matrix, a descriptive title, and a list of admin personae that hold those permissions for objects they own. There are a few specific instances of SchemaConstants.PermBase that don't properly need the list of admin personae, as their object invids are hard-coded into the Ganymede security system, and their permission matrices are automatically consulted in certain situations. In order to support this, we're going to want to have a DBEditObject subclass for managing permission objects. In that subclass, we'll define instantiateNewField() so that it will return false if the fieldID corresponds to the admin personae list if the object's ID is that of one of these special objects. As a result, when the objects are viewed by an administrator, the admin personae list will not be seen.

Overrides:
instantiateNewField in class DBEditObject

canSeeField

public boolean canSeeField(arlut.csd.ganymede.DBSession session,
                           arlut.csd.ganymede.DBField field)
Customization method to verify whether the user should be able to see a specific field in a given object. Instances of DBField will wind up calling up to here to let us override the normal visibility process.

Note that it is permissible for session to be null, in which case this method will always return the default visiblity for the field in question.

If field is not from an object of the same base as this DBEditObject, an exception will be thrown.

To be overridden in DBEditObject subclasses.

Overrides:
canSeeField in class DBEditObject