Package com.webmethods.portal.mech.dir
Interface IDirSystemMechanics
- All Superinterfaces:
IComponent
,IInitializable
,IMechanics
,ISystemHandler
,IViewableMechanics
Date: Aug 13, 2004
-
Field Summary
Fields inherited from interface com.webmethods.portal.mech.view.IViewableMechanics
COMMENTS_LINK_TYPE, CONTENT_LINK_TYPE, DEFAULT_ORDER, DEFAULT_PAGE_SIZE, DEFAULT_SORT, DETAILS_LINK_TYPE, LARGE_ICON_TYPE, LINK_TYPE, LINK_TYPE_COMMENTS, LINK_TYPE_CONTENT, LINK_TYPE_DETAILS, LINK_TYPE_EDIT, LINK_TYPE_HELP, LINK_TYPE_HELP_MAXIMIZED, LINK_TYPE_MAXIMIZED, LINK_TYPE_MINIMIZED, LINK_TYPE_PERMISSIONS, LINK_TYPE_PORTAL_CONTENT, LINK_TYPE_PORTLET_STANDALONE, LINK_TYPE_PROPERTIES, LINK_TYPE_RESTORED, LINK_TYPE_SUBSCRIPTIONS, LINK_TYPE_THUMBNAILS, LINK_TYPE_VERSIONS, PERMISSIONS_LINK_TYPE, PORTAL_CONTENT_LINK_TYPE, PROPERTIES_LINK_TYPE, PROPERTY_LINK_TARGET, PROPERTY_OWNER_NAME, PROPERTY_PARENT_NAME, PROPERTY_TOOLTIP, REFERENCE_ICON_TYPE, SUBSCRIPTIONS_LINK_TYPE, THUMBNAIL_ICON_TYPE, THUMBNAILS_LINK_TYPE, VERSIONS_LINK_TYPE
-
Method Summary
Modifier and TypeMethodDescriptionauthenticateUser
(String userid, String password) Attempts to authenticate the user based on the credentials with any registered directory service in their configured search order.default IDirUser
authenticateUser
(String userid, String password, String oneTimePassword) boolean
hasAdminRole
(IDirPrincipal dirPrincipal) listDirectoryServices
(IThingID userID) Retrieves the list ofIThing
s which are portlets which implement theIDirService
interface and are currently configured.Retrieves the list ofIThing
s that are portlets which implement theIDirService
interface.listPrincipalAttributeProviders
(int type) Gets all the avaliableIPrincipalAttributeProvider
for a specific typelistRoleProviders
(IThingID userID) Retrieves the list ofIThing
s which are portlets which implement theIRoleProvider
interface and are currently configured.List the available roleslookupPrincipalByAlias
(String alias) The aliases can be one of the following: ADMIN_USER_ALIAS: dir.admin.user EVERYONE_GROUP_ALIAS: dir.everyone.group GUEST_USER_ALIAS: dir.guest.user ADMIN_ROLE_ALIAS: dir.admin.rolelookupPrincipalByDN
(String principalDN, int type) Attempts to lookup a principal by their dn.lookupPrincipalByID
(String principalID, int type) Attempts to lookup a principal by their id.lookupPrincipalByURI
(IURI principalUri) Attempts to lookup a principal by their dn.The aliases can be one of the following: ADMIN_USER_ALIAS: dir.admin.user EVERYONE_GROUP_ALIAS: dir.everyone.group GUEST_USER_ALIAS: dir.guest.user ADMIN_ROLE_ALIAS: dir.admin.roleMethods inherited from interface com.webmethods.portal.system.IComponent
getComponentData, getComponentName, getComponentProvider, getURI, isInitialized, setComponentData, setComponentProvider
Methods inherited from interface com.webmethods.portal.system.init.IInitializable
init, shutdown
Methods inherited from interface com.webmethods.portal.mech.view.IViewableMechanics
canView, checkView, createPagingCookie, fireViewEvent, getCss, getCss, getDefaultLinkType, getFormattedProperty, getHierachicalUri, getIcon, getIcon, getLink, getLink, getListProperty, getListPropertyHTML, getListPropertyJS, isEnabled, view, view
-
Method Details
-
getAdminUserID
- Returns:
- the
IThingID
of the admin user - Throws:
PortalException
-
getAdminUser
- Returns:
- the
IDirUser
of the admin user - Throws:
PortalException
-
getEveryoneGroupID
- Returns:
- the
IThingID
of the everyone group - Throws:
PortalException
-
getEveryoneGroup
- Returns:
- the
IDirGroup
of the everyone group - Throws:
PortalException
-
getGuestUserID
- Returns:
- the
IThingID
of the guest user - Throws:
PortalException
-
getGuestUser
- Returns:
- the
IDirUser
of the guest user - Throws:
PortalException
-
getAdminRoleID
- Returns:
- the
IThingID
of the admin role - Throws:
PortalException
-
getAdminRole
- Returns:
- the
IDirRole
of the admin role - Throws:
PortalException
-
hasAdminRole
- Parameters:
dirPrincipal
-- Returns:
- whether or not the user is a member of the admin role
- Throws:
PortalException
-
lookupPrincipalByID
Attempts to lookup a principal by their id. Delegates to the directory service in their configured search order. If found, this principal will be guaranteed to be initialized- Parameters:
principalID
-type
- one ofcom.webmethods.portal.service.dir.IDirSystem.TYPE_USER
com.webmethods.portal.service.dir.IDirSystem.TYPE_GROUP
orcom.webmethods.portal.service.dir.IDirSystem.TYPE_ROLE
- Returns:
- the found IDirPrincipal or null
- Throws:
PortalException
-
lookupPrincipalByDN
Attempts to lookup a principal by their dn. Delegates to the directory service in their configured search order. If found, this principal will be guaranteed to be initialized- Parameters:
principalDN
-type
- one ofcom.webmethods.portal.service.dir.IDirSystem.TYPE_USER
com.webmethods.portal.service.dir.IDirSystem.TYPE_GROUP
orcom.webmethods.portal.service.dir.IDirSystem.TYPE_ROLE
- Returns:
- the found IDirPrincipal or null
- Throws:
PortalException
-
lookupPrincipalByURI
Attempts to lookup a principal by their dn. Delegates to the directory service in their configured search order. If found, this principal will be guaranteed to be initialized- Parameters:
principalUri
-- Returns:
- the found IDirPrincipal or null
- Throws:
PortalException
-
lookupPrincipalByAlias
The aliases can be one of the following:- ADMIN_USER_ALIAS: dir.admin.user
- EVERYONE_GROUP_ALIAS: dir.everyone.group
- GUEST_USER_ALIAS: dir.guest.user
- ADMIN_ROLE_ALIAS: dir.admin.role
- Throws:
PortalException
-
lookupPrincipalThingIDByAlias
The aliases can be one of the following:- ADMIN_USER_ALIAS: dir.admin.user
- EVERYONE_GROUP_ALIAS: dir.everyone.group
- GUEST_USER_ALIAS: dir.guest.user
- ADMIN_ROLE_ALIAS: dir.admin.role
- Throws:
PortalException
-
authenticateUser
IDirUser authenticateUser(String userid, String password) throws PortalException, AuthenticationException Attempts to authenticate the user based on the credentials with any registered directory service in their configured search order.- Parameters:
userid
-password
-- Returns:
- an instance of
IDirUser
which holds critical information describing the user - Throws:
AuthenticationException
PortalException
-
authenticateUser
default IDirUser authenticateUser(String userid, String password, String oneTimePassword) throws PortalException - Parameters:
userid
-password
-oneTimePassword
- Time-Based One-Time Password for two-factor identification- Returns:
- an instance of
IDirUser
which holds critical information describing the user - Throws:
PortalException
-
listRoles
List the available roles- Returns:
- the list of registered roles
- Throws:
PortalException
-
listDirectoryServices
Retrieves the list ofIThing
s which are portlets which implement theIDirService
interface and are currently configured.- Parameters:
userID
-- Returns:
- list of IThingIDs
- Throws:
PortalException
-
listRoleProviders
Retrieves the list ofIThing
s which are portlets which implement theIRoleProvider
interface and are currently configured.- Parameters:
userID
-- Returns:
- list of IThingIDs
- Throws:
PortalException
-
listDirectoryServiceTypes
Retrieves the list ofIThing
s that are portlets which implement theIDirService
interface. These are default instances that are available to be published and configured, but are not currently active. Think of these as templates.- Returns:
- list of IThingIDs
- Throws:
PortalException
-
listPrincipalAttributeProviders
Gets all the avaliableIPrincipalAttributeProvider
for a specific type- Parameters:
type
- one ofcom.webmethods.portal.service.dir.IDirSystem.TYPE_USER
com.webmethods.portal.service.dir.IDirSystem.TYPE_GROUP
orcom.webmethods.portal.service.dir.IDirSystem.TYPE_ROLE
- Returns:
- list of thingids
- Throws:
PortalException
-