IsGroupActive(Group: IMetaAttributeGroup): Boolean;
Group. A group of time series database attributes.
The IsGroupActive method returns whether factor is included in the specified group.
If IsGroupActive returns True, time series is included in the specified group.
The IMetaDictionaryDataInfo.IsAttributeActive method returns whether a specified group attribute is available for the time series.
Executing the example requires a time series database with the FC_GROUPS identifier that contains a group attribute. Add links to the Rds, Metabase, Cubes system assemblies.
Sub UserProc;
Var
mb: IMetabase;
RubDesc: IMetabaseObjectDescriptor;
Rub: IRubricator;
RubrIn: IRubricatorInstance;
Dic: IMetaDictionary;
i: Integer;
key: Array Of Integer;
Grp: IMetaAttributeGroup;
FactsLookup: IRubricatorFactsLookup;
FactData: IRubricatorFactData;
FactInfo: IMetaDictionaryDataInfo;
Begin
mb := MetabaseClass.Active;
RubDesc := mb.ItemById("FC_GROUPS");
Rub := RubDesc.Bind As IRubricator;
// Receive database time series dictionary
Dic := (Rub.Facts As IMetabaseObject).Edit As IMetaDictionary;
// Receive the first group of dictionary attributes
Grp := Dic.Groups.Item(0);
// Receive array of time series keys
RubrIn := RubDesc.Open(Null) As IRubricatorInstance;
FactsLookup := RubrIn.CreateFactsLookup;
i := FactsLookup.LookupFactors.Length;
key := New Integer[i];
key := FactsLookup.LookupFactors;
// Receive time series that are included in the first group of attributes
For Each i In key Do
FactData := RubrIn.GetFactData(i);
FactInfo := FactData As IMetaDictionaryDataInfo;
If FactInfo.IsGroupActive(Grp) Then
Debug.WriteLine(FactData.Mnemo);
End If;
End For;
End Sub UserProc;
After executing the example, the mnemonics of factors, the group attribute value of which can be changed, are displayed in the console window.
See also: