Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jasig.portal.channels.groupsmanager
Class SearchResultsGroupImpl

    java.lang.Object
      org.jasig.portal.channels.groupsmanager.SearchResultsGroupImpl

All Implemented Interfaces:
  IEntityGroup, IGroupMember, IBasicEntity

    public class SearchResultsGroupImpl

extends java.lang.Object
implements IEntityGroup

SearchResultsGroupImp summary description sentence goes here.

Version:
  $Revision: 1.5 $

Field Summary
`protected java.lang.String` | `creator`
`protected java.lang.String` | `description`
`protected EntityIdentifier` | `ei`
`protected java.lang.Class` | `leafType`
`protected java.util.ArrayList` | `members`
`protected java.lang.String` | `name`

Constructor Summary
`SearchResultsGroupImpl(java.lang.Class leafType)`

Method Summary
`void` | `addMember(IGroupMember gm)` Adds `IGroupMember` gm to this group, but does not commit it to the data store.
`boolean` | `contains(IGroupMember gm)` Answers if `IGroupMember` gm is a member of `this`.
`boolean` | `deepContains(IGroupMember gm)` Answers if `IGroupMember` gm is a recursive member of `this`.
`void` | `delete()` Deletes the `IEntityGroup` from the data store.
`boolean` | `equals(java.lang.Object o)` Answers if Object o is an `IGroupMember` that refers to the same underlying entity(ies) as `this`.
`java.util.Iterator` | `getAllContainingGroups()` Returns an `Iterator` over the `Set` of this `IGroupMember's` recursively-retrieved parent groups.
`java.util.Iterator` | `getAllEntities()` Returns an `Iterator` over the `Set` of this `IGroupMember's` recursively-retrieved members that are `IEntities`.
`java.util.Iterator` | `getAllMembers()` Returns an `Iterator` over the `Set` of recursively-retrieved `IGroupMembers` that are members of `this`.
`java.util.Iterator` | `getContainingGroups()` Returns an `Iterator` over this `IGroupMember's` parent groups.
`java.lang.String` | `getCreatorID()` Returns the name of the group creator.
`java.lang.String` | `getDescription()` Returns the group description, which may be null.
`java.util.Iterator` | `getEntities()` Returns an `Iterator` over this `IGroupMember's` members that are `IEntities`.
`EntityIdentifier` | `getEntityIdentifier()`
`java.lang.Class` | `getEntityType()` Returns the underlying entity type.
`java.lang.String` | `getKey()` Returns the key of the underlying entity.
`java.lang.Class` | `getLeafType()`
`java.lang.String` | `getLocalKey()` Returns the key from the group service of origin.
`IEntityGroup` | `getMemberGroupNamed(java.lang.String name)` Returns the named `IEntityGroup` from our members `Collection`.
`java.util.Iterator` | `getMembers()` Returns an `Iterator` over the `IGroupMembers` in our member `Collection`.
`java.lang.String` | `getName()` Returns the group name.
`javax.naming.Name` | `getServiceName()` Returns the Name of the group service of origin.
`java.lang.Class` | `getType()` Returns the type of the underlying entity.
`EntityIdentifier` | `getUnderlyingEntityIdentifier()` Returns `EntityIdentifier` for this `IGroupMember's` underlying entity.
`boolean` | `hasMembers()` Answers if this `IGroupMember` has any members.
`boolean` | `isDeepMemberOf(IGroupMember gm)` Answers if `this` is a recursive member of `IGroupMember` gm.
`boolean` | `isEditable()` Answers if this `IEntityGroup` can be changed or deleted.
`boolean` | `isEntity()`
`boolean` | `isGroup()`
`boolean` | `isMemberOf(IGroupMember gm)` Answers if `this` is a member of `IGroupMember` gm.
`void` | `removeMember(IGroupMember gm)` Removes the `IGroupMember` from this group, but does not remove the membership from the data store.
`void` | `setCreatorID(java.lang.String userID)`
`void` | `setDescription(java.lang.String name)`
`void` | `setLocalGroupService(IIndividualGroupService groupService)` Sets the group service of origin.
`void` | `setName(java.lang.String name)` Sets the group name which must be unique within any of its containing groups.
`void` | `update()` Commit the `IEntityGroup` AND ITS MEMBERSHIPS to the data store.
`void` | `updateMembers()` Commit this `IEntityGroup's` memberships to the data store.

Methods inherited from class java.lang.Object
`clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.jasig.portal.groups.IGroupMember
`hashCode`

Field Detail

### members

    protected java.util.ArrayList members

### name

    protected java.lang.String name

### description

    protected java.lang.String description

### creator

    protected java.lang.String creator

### ei

    protected EntityIdentifier ei

### leafType

    protected java.lang.Class leafType

Constructor Detail

### SearchResultsGroupImpl

    public SearchResultsGroupImpl(java.lang.Class leafType)

Method Detail

### addMember

    public void addMember(IGroupMember gm)
                   throws GroupsException

  Description copied from interface: `IEntityGroup`
  Adds `IGroupMember` gm to this group, but does not commit it to the data store. Use `updateMembers()` to commit memberships to the data store.

  Specified by:
    `addMember` in interface `IEntityGroup`
  Parameters:
    `gm` - org.jasig.portal.groups.IGroupMember
  Throws:
    `GroupsException` - is thrown if the member is a group and this group already has a group with the same name or if the addition of the group creates a circular reference.

### getMembers

    public java.util.Iterator getMembers()
                                  throws GroupsException

  Description copied from interface: `IGroupMember`
  Returns an `Iterator` over the `IGroupMembers` in our member `Collection`.

  Specified by:
    `getMembers` in interface `IGroupMember`
  Returns:
    java.util.Iterator
  Throws:
    `GroupsException`

### getCreatorID

    public java.lang.String getCreatorID()

  Description copied from interface: `IEntityGroup`
  Returns the name of the group creator. May be null.

  Specified by:
    `getCreatorID` in interface `IEntityGroup`
  Returns:
    String

### getDescription

    public java.lang.String getDescription()

  Description copied from interface: `IEntityGroup`
  Returns the group description, which may be null.

  Specified by:
    `getDescription` in interface `IEntityGroup`
  Returns:
    String

### getLocalKey

    public java.lang.String getLocalKey()

  Description copied from interface: `IEntityGroup`
  Returns the key from the group service of origin.

  Specified by:
    `getLocalKey` in interface `IEntityGroup`
  Returns:
    String

### getName

    public java.lang.String getName()

  Description copied from interface: `IEntityGroup`
  Returns the group name.

  Specified by:
    `getName` in interface `IEntityGroup`
  Returns:
    String

### getServiceName

    public javax.naming.Name getServiceName()

  Description copied from interface: `IEntityGroup`
  Returns the Name of the group service of origin.

  Specified by:
    `getServiceName` in interface `IEntityGroup`
  Returns:
    String

### removeMember

    public void removeMember(IGroupMember gm)

  Description copied from interface: `IEntityGroup`
  Removes the `IGroupMember` from this group, but does not remove the membership from the data store.

  Specified by:
    `removeMember` in interface `IEntityGroup`
  Parameters:
    `gm` - org.jasig.portal.groups.IGroupMember

### setCreatorID

    public void setCreatorID(java.lang.String userID)

  Specified by:
    `setCreatorID` in interface `IEntityGroup`
  Parameters:
    `userID` - String (required)

### setDescription

    public void setDescription(java.lang.String name)

  Specified by:
    `setDescription` in interface `IEntityGroup`
  Parameters:
    `name` - String (may be null)

### setName

    public void setName(java.lang.String name)
                 throws GroupsException

  Description copied from interface: `IEntityGroup`
  Sets the group name which must be unique within any of its containing groups.

  Specified by:
    `setName` in interface `IEntityGroup`
  Parameters:
    `name` - String
  Throws:
    `GroupsException`

### setLocalGroupService

    public void setLocalGroupService(IIndividualGroupService groupService)
                              throws GroupsException

  Description copied from interface: `IEntityGroup`
  Sets the group service of origin.

  Specified by:
    `setLocalGroupService` in interface `IEntityGroup`
  Throws:
    `GroupsException`

### contains

    public boolean contains(IGroupMember gm)
                     throws GroupsException

  Description copied from interface: `IGroupMember`
  Answers if `IGroupMember` gm is a member of `this`.

  Specified by:
    `contains` in interface `IGroupMember`
  Parameters:
    `gm` - org.jasig.portal.groups.IGroupMember
  Returns:
    boolean
  Throws:
    `GroupsException`

### deepContains

    public boolean deepContains(IGroupMember gm)
                         throws GroupsException

  Description copied from interface: `IGroupMember`
  Answers if `IGroupMember` gm is a recursive member of `this`.

  Specified by:
    `deepContains` in interface `IGroupMember`
  Parameters:
    `gm` - org.jasig.portal.groups.IGroupMember
  Returns:
    boolean
  Throws:
    `GroupsException`

### equals

    public boolean equals(java.lang.Object o)

  Description copied from interface: `IGroupMember`
  Answers if Object o is an `IGroupMember` that refers to the same underlying entity(ies) as `this`.

  Specified by:
    `equals` in interface `IGroupMember`
  Overrides:
    `equals` in class `java.lang.Object`
  Returns:
    boolean

### getAllContainingGroups

    public java.util.Iterator getAllContainingGroups()
                                              throws GroupsException

  Description copied from interface: `IGroupMember`
  Returns an `Iterator` over the `Set` of this `IGroupMember's` recursively-retrieved parent groups.

  Specified by:
    `getAllContainingGroups` in interface `IGroupMember`
  Returns:
    java.util.Iterator
  Throws:
    `GroupsException`

### getAllEntities

    public java.util.Iterator getAllEntities()
                                      throws GroupsException

  Description copied from interface: `IGroupMember`
  Returns an `Iterator` over the `Set` of this `IGroupMember's` recursively-retrieved members that are `IEntities`.

  Specified by:
    `getAllEntities` in interface `IGroupMember`
  Returns:
    java.util.Iterator
  Throws:
    `GroupsException`

### getAllMembers

    public java.util.Iterator getAllMembers()
                                     throws GroupsException

  Description copied from interface: `IGroupMember`
  Returns an `Iterator` over the `Set` of recursively-retrieved `IGroupMembers` that are members of `this`.

  Specified by:
    `getAllMembers` in interface `IGroupMember`
  Returns:
    java.util.Iterator
  Throws:
    `GroupsException`

### getContainingGroups

    public java.util.Iterator getContainingGroups()
                                           throws GroupsException

  Description copied from interface: `IGroupMember`
  Returns an `Iterator` over this `IGroupMember's` parent groups.

  Specified by:
    `getContainingGroups` in interface `IGroupMember`
  Returns:
    java.util.Iterator
  Throws:
    `GroupsException`

### getEntities

    public java.util.Iterator getEntities()
                                   throws GroupsException

  Description copied from interface: `IGroupMember`
  Returns an `Iterator` over this `IGroupMember's` members that are `IEntities`.

  Specified by:
    `getEntities` in interface `IGroupMember`
  Returns:
    java.util.Iterator
  Throws:
    `GroupsException`

### getEntityType

    public java.lang.Class getEntityType()

  Description copied from interface: `IGroupMember`
  Returns the underlying entity type. For an `IEntityGroup`, this is analagous to `Class` as applied to an `Array`; it is an attribute of the group object. For an `IEntity`, it is the entity type of the group the entity belongs to, which may be any `Class` the underlying entity can be legally cast to. Thus, an `IEntity` with an underlying entity of type `Manager` could have an entity type of `Employee` as long as `Employee` was a superclass of `Manager`.

  Specified by:
    `getEntityType` in interface `IGroupMember`
  Returns:
    java.lang.Class

### getKey

    public java.lang.String getKey()

  Description copied from interface: `IGroupMember`
  Returns the key of the underlying entity.

  Specified by:
    `getKey` in interface `IGroupMember`
  Returns:
    String

### getLeafType

    public java.lang.Class getLeafType()

  Specified by:
    `getLeafType` in interface `IGroupMember`
  See Also:
    `IGroupMember.getEntityType()`

### getMemberGroupNamed

    public IEntityGroup getMemberGroupNamed(java.lang.String name)
                                     throws GroupsException

  Description copied from interface: `IGroupMember`
  Returns the named `IEntityGroup` from our members `Collection`.

  Specified by:
    `getMemberGroupNamed` in interface `IGroupMember`
  Parameters:
    `name` - java.lang.String
  Returns:
    org.jasig.portal.groups.IEntityGroup
  Throws:
    `GroupsException`

### getType

    public java.lang.Class getType()

  Description copied from interface: `IGroupMember`
  Returns the type of the underlying entity. For a group this will be `IEntityGroup`. For an entity, it will be the type of the underlying `EntityIdentifier`.

  Specified by:
    `getType` in interface `IGroupMember`
  Returns:
    java.lang.Class

### getUnderlyingEntityIdentifier

    public EntityIdentifier getUnderlyingEntityIdentifier()

  Description copied from interface: `IGroupMember`
  Returns `EntityIdentifier` for this `IGroupMember's` underlying entity. In the case of an `IEntityGroup`, it will be the `EntityIdentifier` for `this`. In the case of an `IEntity`, it will be the `EntityIdentifier` that identifies the underlying IPerson, ChannelDefinition, etc.

  Specified by:
    `getUnderlyingEntityIdentifier` in interface `IGroupMember`
  Returns:
    org.jasig.portal.EntityIdentifier

### isDeepMemberOf

    public boolean isDeepMemberOf(IGroupMember gm)
                           throws GroupsException

  Description copied from interface: `IGroupMember`
  Answers if `this` is a recursive member of `IGroupMember` gm.

  Specified by:
    `isDeepMemberOf` in interface `IGroupMember`
  Parameters:
    `gm` - org.jasig.portal.groups.IGroupMember
  Returns:
    boolean
  Throws:
    `GroupsException`

### isMemberOf

    public boolean isMemberOf(IGroupMember gm)
                       throws GroupsException

  Description copied from interface: `IGroupMember`
  Answers if `this` is a member of `IGroupMember` gm.

  Specified by:
    `isMemberOf` in interface `IGroupMember`
  Parameters:
    `gm` - org.jasig.portal.groups.IGroupMember
  Returns:
    boolean
  Throws:
    `GroupsException`

### getEntityIdentifier

    public EntityIdentifier getEntityIdentifier()

  Specified by:
    `getEntityIdentifier` in interface `IBasicEntity`
  Returns:
    EntityIdentifier

### update

    public void update()
                throws GroupsException

  Description copied from interface: `IEntityGroup`
  Commit the `IEntityGroup` AND ITS MEMBERSHIPS to the data store.

  Specified by:
    `update` in interface `IEntityGroup`
  Throws:
    `GroupsException` - if the update cannot be performed.

### updateMembers

    public void updateMembers()
                       throws GroupsException

  Description copied from interface: `IEntityGroup`
  Commit this `IEntityGroup's` memberships to the data store.

  Specified by:
    `updateMembers` in interface `IEntityGroup`
  Throws:
    `GroupsException` - if the update cannot be performed.

### isEditable

    public boolean isEditable()
                       throws GroupsException

  Description copied from interface: `IEntityGroup`
  Answers if this `IEntityGroup` can be changed or deleted.

  Specified by:
    `isEditable` in interface `IEntityGroup`
  Returns:
    boolean
  Throws:
    `GroupsException`

### delete

    public void delete()
                throws GroupsException

  Description copied from interface: `IEntityGroup`
  Deletes the `IEntityGroup` from the data store.

  Specified by:
    `delete` in interface `IEntityGroup`
  Throws:
    `GroupsException` - if the delete cannot be performed.

### hasMembers

    public boolean hasMembers()
                       throws GroupsException

  Description copied from interface: `IGroupMember`
  Answers if this `IGroupMember` has any members.

  Specified by:
    `hasMembers` in interface `IGroupMember`
  Returns:
    boolean
  Throws:
    `GroupsException`

### isEntity

    public boolean isEntity()

  Specified by:
    `isEntity` in interface `IGroupMember`
  Returns:
    boolean

### isGroup

    public boolean isGroup()

  Specified by:
    `isGroup` in interface `IGroupMember`
  Returns:
    boolean

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD