IMetaHierarchyAttributes.MoveAllToNew

Syntax

MoveAllToNew(Attributes: IMetaAttributes; LevelBefore: IMetaHierarchyLevel): IMetaHierarchyLevel;

Parameters

Attribute - attributes that are necessary to select in the separate level.

LevelBefore - hierarchy level, before which it is necessary to create the level.

Description

The MoveAllToNew method selects attributes collection in the separate level.

Example

Executing the example requires that the repository contains a time series database with the OBJ_FC identifier.

Sub Main;

Var

Mb: Imetabase;

Rubr: IRubricator;

Facts: IMetaDictionary;

Hierarchy: IMetaHierarchy;

HAttributes: IMetaHierarchyAttributes;

HLev: IMetaHierarchyLevel;

Begin

Mb := MetabaseClass.Active;

Rubr := MB.ItemById("OBJ_FC").Bind As IRubricator;

Facts := Rubr.Facts;

Hierarchy := Facts.DefaultHierarchy;

HAttributes := Hierarchy.Attributes;

HLev := HAttributes.MoveToNew(Facts.Attributes, Hierarchy.Levels.Leaf);

End Sub Main;

After executing the example all attributes of time series database are selected in the separate level of the hierarchy. The created level is put before the leaf level of the hierarchy.

See also:

IMetaHierarchyAttributes