Adapter Development Kit 9.12 | webMethods Adapter Development Kit Documentation | webMethods Adapter Development Kit Installation and User’s Documentation | Adapter Services | Metadata Model for Adapter Services | Field Maps with Resource Domain Dependencies
 
Field Maps with Resource Domain Dependencies
The addResourceDomainLookup and adapterCheckValue methods have a values[][] argument that contains the current value(s) of the parameter(s) on which the resource domain association depends. If the dependency parameter is a sequence parameter, the complete list of values is provided in the values argument. However, when a parameter depends on another parameter in the same field map, then by default each row in the field map is handled separately, for resource domain lookup/check value purposes.
For example, assume that with the sequence parameters A and B, the lookup for B depends on A. If the parameters are not in the same field map, then whenever a row in A changes, a lookup is performed for B, to which all values of A are passed. The results list is applied to each row of B, and updates are made to any rows of B that are no longer valid. The rows may be no longer valid because their values are not members of a "complete" resource domain (that is, a resource domain that does not allow the users of the adapter to enter values), or because an adapter check value callback failed to validate the rows.
However, if A and B are in the same field map, then when the value in a row of A changes, only the new value in that row is passed to the resource domain lookup, and the values returned from the lookup apply only to that row of B. For example, if parameter A contains catalog item numbers, and parameter B contains the colors in which the item is available, then for each catalog item number in A, there would be a separate dropdown list of available colors in column B. Also note that if the same catalog item number appeared in multiple rows in column A, then the dropdown list of colors in column B would be the same. There would not be a separate resource domain lookup for each of those rows because the adapter service editor would recognize that it already has the list of colors for that item number. Or, more accurately, that it already has a list of resource domain values based on the given set of dependency parameter values.
If you want to suppress the behavior described above, prefix the name of the parameter in the setResourceDomain dependency list with an asterisk (*). For example, the following method causes Integration Server to treat parameter A like any other parameter, even if it were in a field map with B:
setResourceDomain("B", "bLookup", new String[] {"*A"})