SysGeneralizableExtensionAppFactory::getExtensionForAttribute Method [AX 2012]

Gets a single extension for a given base class and a given attribute.

Syntax

client server public static Object getExtensionForAttribute(
    ClassName _baseClassName, 
    SysGeneralizableAttribute _attribute, 
   [anytype _parameter])

Run On

Called

Parameters

  • _parameter
    Type: anytype
    A parameter to provide to the isApplicableTo method of the SysIConditionalExtension interface, if the extension implements it.

Return Value

Type: Object Class
An instantiated extension.

Exceptions

Exception Condition
Error

Multiple extensions were found.

Remarks

The method looks for the most specific extension by the given parameters.

During lookup, the method prefers more specific attribute values to less specific (first, extension marked with value equal to _attribute, then extension marked with value equal to _attribute.getMoreGeneral(), and so on).

If several extensions are bound to the same attribute value, extensions that support the SysIConditionalExtension interface are better.

See Also

Reference

SysGeneralizableExtensionAppFactory Class