ARoad0.gBaseInterface
Interface NoThanViewInBase

All Superinterfaces:
BaseObject, BoundBean, EPRViewInBase, java.util.EventListener, Folder, ImmutableFolder, java.beans.PropertyChangeListener, ViewInBase
All Known Implementing Classes:
NoThanViewInBaseImpl

public interface NoThanViewInBase
extends EPRViewInBase

This class is responsible for managing the No-More-Than and No-Less-Than views. The aim is to check if some Eligible Parties (or Sources) has rights on the access target above a given 'no-more' right and below a given 'no-less' right. The 'less' right criteria is generally used to check the compliance to the access needs. The 'more' right criteria is generally used to check the compliance to the access security policy. This view handles one Target, a set of Sources, another set of excluded Sources which belong or run under one of the first-set Source, a StringRight 'more' criteria and a StringRight 'less' criteria. Caution: indeed, every Source is a Target, since a GroupDMember for example is the target of the RUN_UNDER relation.

See Also:
GraphicNoThanView

Method Summary
 void addEorExcludedSource(ImmutableSource _sour)
          An excluded Source is in the perimeter of checking, but has not to be checked.
 void addEorNoThanAccessTarget(ImmutableTarget _targ)
          This view handles exactly one target, in this class version.
 boolean containsExcludedSource(ImmutableSource _sour)
          An excluded Source is connected to a view basic Source, but it has not to be checked since it is explicitly put away by the user.
 NoThanViewInBase copyAndSave(ImmutableName _name)
          Creates, registers in the base and saves a view copy with another name.
 java.util.Set<ImmutableSource> getCheckingPerimeter()
          List of Sources which are in the perimeter of checking, and that includes the view BaseObjects and the listening perimeter.
 ImmutableTarget getEorFirstAccessTarget()
          This view handles exactly one target.
 java.util.List<ImmutableSource> getExcludedSources()
          An excluded Source is connected to a view basic Source, but it has not to be checked since it is explicitly put away by the user.
 StringRight getLessCriterion()
          The aim is to check if an Eligible Party has rights on the target, which are below the 'less' criteria.
 StringRight getMoreCriterion()
          The aim is to check if an Eligible Party has rights on the target, which are below the 'more' criteria.
 java.util.Set<ImmutableSource> getReducedSourcesInViewSources()
          List of Sources from the view Sources list which have at most a connected member or a running-under actor being an excluded Source.
 void removeEorExcludedSource(ImmutableSource _sour)
          An excluded Source is in the perimeter of checking, but has not to be checked.
 void removeEorNoThanAccessTarget(ImmutableTarget _targ)
          This view handles exactly one target.
 void setEorFirstAccessTarget(ImmutableTarget _targ)
          This view handles exactly one access target.
 void setLessCriterion(StringRight _right)
          The aim is to check if an Eligible Party has rights on the target, which are below the 'less' criteria.
 void setMoreCriterion(StringRight _right)
          The aim is to check if an Eligible Party has rights on the target, which are above the 'more' criteria.
 
Methods inherited from interface ARoad0.gBaseInterface.EPRViewInBase
addEorSource, addEorTarget, containsSource, containsTarget, getEorM_NoSourceTargets, getEorM_Sources, getEorM_Targets, removeEorSource, removeEorTarget
 
Methods inherited from interface ARoad0.gBaseInterface.ViewInBase
getCompleteResults
 
Methods inherited from interface ARoad0.gBaseInterface.Folder
addEorBaseObject, addPropertyChangeListener, addPropertyChangeListener, propertyChange, removeEorBaseObject, removePropertyChangeListener, removePropertyChangeListener, setComment
 
Methods inherited from interface ARoad0.gBaseInterface.ImmutableFolder
containsBaseObject, getComment, getConnectedToSeveralACS, getEorL_ConnectedACSNames, getEorM_BaseObjects, getType, isEmpty
 
Methods inherited from interface ARoad0.gBaseInterface.BaseObject
equals, getFullName, getName, getNickName, hashCode
 

Method Detail

getEorFirstAccessTarget

ImmutableTarget getEorFirstAccessTarget()
This view handles exactly one target.

Returns:
the target. May be null only before the first updating.

setEorFirstAccessTarget

void setEorFirstAccessTarget(ImmutableTarget _targ)
                             throws BaseError
This view handles exactly one access target. The More and Less criteria are set to null.

Parameters:
_targ - the target to add. Never null, so a current target cannot be removed.
Throws:
BaseError - if the target is also a registered source in this view, if the number of targets is too large, if the argument is null, or the object name is null or empty.

addEorNoThanAccessTarget

void addEorNoThanAccessTarget(ImmutableTarget _targ)
                              throws BaseError
This view handles exactly one target, in this class version.

Parameters:
_targ - the target to add
Throws:
BaseError - if the target is also a registered source in this view, if the number of targets is too large, if the argument is null, or the object name is null or empty.

removeEorNoThanAccessTarget

void removeEorNoThanAccessTarget(ImmutableTarget _targ)
                                 throws BaseError
This view handles exactly one target.

Parameters:
_targ - the target to remove
Throws:
BaseError - if the argument is not the current target, if the argument is null, or the object name is null or empty.

getMoreCriterion

StringRight getMoreCriterion()
The aim is to check if an Eligible Party has rights on the target, which are below the 'more' criteria.

Returns:
the 'more' criteria. May be null.

setMoreCriterion

void setMoreCriterion(StringRight _right)
                      throws BaseError
The aim is to check if an Eligible Party has rights on the target, which are above the 'more' criteria.

Parameters:
_right - is the 'more' criteria
Throws:
BaseError - if the argument is null.

getLessCriterion

StringRight getLessCriterion()
The aim is to check if an Eligible Party has rights on the target, which are below the 'less' criteria.

Returns:
the 'less' criteria. May be null.

setLessCriterion

void setLessCriterion(StringRight _right)
                      throws BaseError
The aim is to check if an Eligible Party has rights on the target, which are below the 'less' criteria.

Parameters:
_right - is the 'less' criteria
Throws:
BaseError - if the argument is null.

getExcludedSources

java.util.List<ImmutableSource> getExcludedSources()
An excluded Source is connected to a view basic Source, but it has not to be checked since it is explicitly put away by the user. So its compliance to the more and to the less criteria will stay unknown.

Returns:
list of the excluded sources. Never null.

containsExcludedSource

boolean containsExcludedSource(ImmutableSource _sour)
An excluded Source is connected to a view basic Source, but it has not to be checked since it is explicitly put away by the user. So its compliance to the more and to the less criteria will stay unknown.

Parameters:
_sour - to test
Returns:
true if the view references this Source as excluded

getCheckingPerimeter

java.util.Set<ImmutableSource> getCheckingPerimeter()
List of Sources which are in the perimeter of checking, and that includes the view BaseObjects and the listening perimeter. Gets the checking perimeter which includes the view BaseObjects and the listening perimeter. The associates of an Source are defined as their direct/indirect members and their direct/indirect running-under actors. This listening perimeter is get by the subtraction of the excluded Sources and their associates from the view Sources list (also called 'basic rights users') and their associates.

For instance, if the group A is a view Source, and has only group B and group C has direct members, and if the group C is a view excluded Source, the listening perimeter contains only the group B and its associates.

The Sources in the listening perimeter do not registered this NoThanViewInBase has an implied view. The size is limited to 50.

Returns:
the Sources in the checking perimeter. Never null.

getReducedSourcesInViewSources

java.util.Set<ImmutableSource> getReducedSourcesInViewSources()
List of Sources from the view Sources list which have at most a connected member or a running-under actor being an excluded Source. Do not contain the reduced Sources in the checking perimeter which are not view Sources, that is when they are members or running-under Actors of a view Source.

Returns:
the Sources. Never null.

addEorExcludedSource

void addEorExcludedSource(ImmutableSource _sour)
                          throws BaseError
An excluded Source is in the perimeter of checking, but has not to be checked. So its compliance to the more and to the less criteria will stay unknown. The perimeter of checking is defined as the set of the Sources which are registered in the view (but such Source may not be excluded), and the Source which are direct or indirect member of, or run under, a registered Source of the view.

Parameters:
_sour - to exclude
Throws:
BaseError - if the argument is a registered Source, is not in the perimeter of checking, if the argument is null, or the object name is null or empty.

removeEorExcludedSource

void removeEorExcludedSource(ImmutableSource _sour)
                             throws BaseError
An excluded Source is in the perimeter of checking, but has not to be checked. So its compliance to the more and to the less criteria will stay unknown. The perimeter of checking is defined as the set of the Source which are registered in the view (but such Source may not be excluded), and the Source which are direct or indirect member of, or run under, a registered Source of the view.

Parameters:
_sour - non-null Source to remove as excluded Source
Throws:
BaseError - if the Source is unknown as excluded, or if the argument is null, if the object name is empty.

copyAndSave

NoThanViewInBase copyAndSave(ImmutableName _name)
                             throws BaseError
Creates, registers in the base and saves a view copy with another name. Calls copy(). Overrides the super method.

Specified by:
copyAndSave in interface EPRViewInBase
Parameters:
_name - of the copy. It is copied without test.
Returns:
the copied view
Throws:
BaseError - if _name is null or already known in BaseManagerImpl, or if _view is null or not known.