Compare-Attribute
Description
Compares the value of an attribute name to the attribute value parameter for an entry in the directory.
Syntax
<ie:webject name="Compare-Attribute" type="ACT">
<ie:param name="ATTNAME" data="attribute_name"/>
<ie:param name="ATTVALUE" data="attribute_value"/>
<ie:param name="BASE" data="base_context_name"/>
<ie:param name="CONNECTION_ATTEMPT_INTERVAL" data="interval"/>
<ie:param name="CONNECTION_ATTEMPTS" data="attempts"/>
<ie:param name="DBUSER" data="dbuser_name"/>
<ie:param name="GROUP_OUT" data=group_out"/>
<ie:param name="INSTANCE" data="instance_name"/>
<ie:param name="OBJECT" data="object_value"/>
<ie:param name="PASSWD" data="dbpassword"/>
</ie:webject>
Parameters
Required
Optional
ATTNAME
BASE
ATTVALUE
CONNECTION ATTEMPTS
INSTANCE
CONNECTION_ATTEMPT_INTERVAL
DBUSER
GROUP_OUT
OBJECT
PASSWD
ATTNAME
Specifies the attribute name of the entry to be compared with a given value. This is a required parameter.
ATTVALUE
Specifies the value of the attribute for the entry being compared. This is a required parameter.
BASE
Specifies the base distinguished name of the entry at which to start searching. If a value is specified for this parameter, then the webject value takes precedence over the property value specified in the adapter LDAP entry. The default for this parameter is the value specified for the searchBase property in the adapter LDAP entry. This is an optional parameter.
CONNECTION_ATTEMPTS
Defines the maximum number of times to attempt establishing a connection to an adapter before returning an error. The default value is 1. This parameter is optional.
If multiple INSTANCE parameter values are specified, the value of CONNECTION_ATTEMPTS defines the maximum number of times to iterate through the list of adapter instances.
CONNECTION_ATTEMPT_INTERVAL
Defines the amount of time, in seconds, to delay between connection attempts. The default value is 60 seconds. This parameter is optional.
If multiple INSTANCE parameter values are specified, the value of CONNECTION_ATTEMPT_INTERVAL defines the number of seconds to wait between the attempts to iterate through the entire list of adapter instances.
DBUSER
Specifies the name to use when logging in to the data repository. If this parameter is specified in this webject, the webject value takes precedence over any value specified in the credentials mapping settings or in the adapter LDAP entry. If this parameter is not specified here, it must be specified in the credentials mapping settings or in the adapter LDAP entry. For more information about credentials mapping, see the section Credentials Mapping.
GROUP_OUT
Identifies the name of the object set returned by the action. Currently, GROUP_OUT only returns a status message. This parameter is optional.
INSTANCE
Specifies the name of the adapter that executes the webject. Adapter names are defined when the adapter is configured for use in your Info*Engine environment. This parameter is required.
To connect to other adapters if a specific adapter is not available, this parameter can be multi-valued. Info*Engine attempts to connect to the adapters in the order given. If the first adapter specified in not available, the next adapter listed is tried, and so on, until a connection is made. If a connection cannot be established with any listed adapter, an error is returned.
In conjunction with this parameter, you can include two other parameters, CONNECTION_ATTEMPTS and CONNECTION_ATTEMPT_INTERVAL.
OBJECT
Specifies the context name of the entry. One object may be specified. If more than one is specified, the first will be used and the remainder ignored. This is an optional parameter.
PASSWD
Specifies the password to use when logging in to the data repository. If this parameter is specified in this webject, the webject value takes precedence over any value specified in the credentials mapping settings or in the adapter LDAP entry. If this parameter is not specified here, it must be specified in the credentials mapping settings or in the adapter LDAP entry. For more information about credentials mapping, see the section Credentials Mapping.
Example
The Compare-Attribute webject shown in this example instructs Info*Engine to connect to the appropriate adapter instance. Once connected, Info*Engine checks the object "uid=pperson, ou=people" to see if it has an attribute "location" set to "Pontiac".
<%@page language="java" session="false"%>
<%@taglib uri="http://www.ptc.com/infoengine/taglib/core"
prefix="ie"%>
<ie:webject name="Compare-Attribute" type="ACT">
<ie:param name="INSTANCE" data="jndiAdapter"/>
<ie:param name="ATTNAME" data="location"/>
<ie:param name="ATTVALUE" data="Pontiac"/>
<ie:param name="OBJECT" data="uid=pperson, ou=people"
<ie:param name="BASE" data="uid=pperson, ou=people"/>
<ie:param name="GROUP_OUT" data="Compare"/>
</ie:webject>
Было ли это полезно?