EnvironmentAttributes: IABACAttributeInstances;
EnvironmentAttributes: Prognoz.Platform.Interop.ABAC.IABACAttributeInstances;
The EnvironmentAttributes property returns system environment attributes.
The property is read-only.
To execute the example, add links to the ABAC, Metabase system assemblies.
Sub UserProc;
Var
MB: IMetabase;
Env: IABACAttributeInstances;
Attr: IABACAttributeInstance;
i, Count: Integer;
Begin
MB := MetabaseClass.Active;
Env := MB.Security.EnvironmentAttributes;
Count := Env.Count;
For i := 0 To Count-1 Do
Attr := Env.Item(i);
Debug.WriteLine(Attr.Attribute.Name(MB.CurrentLocale));
End For;
End Sub UserProc;
Imports Prognoz.Platform.Interop.ABAC;
Imports Prognoz.Platform.Interop.Metabase;
…
Public Shared Sub Main(Params: StartParams);
Var
MB: IMetabase;
Env: IABACAttributeInstances;
Attr: IABACAttributeInstance;
i, Count: Integer;
Begin
MB := Params.Metabase;
Env := MB.Security.EnvironmentAttributes;
Count := Env.Count;
For i := 0 To Count-1 Do
Attr := Env.Item[i];
System.Diagnostics.Debug.WriteLine(Attr.Attribute.Name[MB.CurrentLocale]);
End For;
End Sub;
After executing the example the console window displays names of system environment attributes.
See also: