Changes

HowTo:Provide system definitions with a custom plugin

286 bytes added, 15:43, 26 November 2024
this.CodedNamespace = "System.MyPlugin";
this.CodedDescription = "My classification";
// Derives from SystemDesignMetaClass, see above for metaproperty definition
}
}
#endregion System Classifications
// ...
}
public override UBIKClassList<SelectiveList> DefineSystemSelectiveLists(UBIKEnvironment environment)
{
UBIKClassList<SelectiveList> selectiveLists = new UBIKClassList<SelectiveList>(); // MyEnumType should be an integer enum SystemSelectiveList fromEnum = new SystemSelectiveList(environment, typeof(MyEnumType)); // MyEnumType should be an integer enum
fromEnum.SetUID(GuidUtility.SLFROMENUM);
selectiveLists.Add(fromEnum); SystemSelectiveList customList = new SystemSelectiveList(environment); customList.SetItemValueType(PropertyTypes.String); customList.AddSelectiveItem("any object of supported type", "description"); customList.Name = "SL_STR"; customList.SetUID(GuidUtility.SLSTR); selectiveLists.Add(customList); return selectiveLists;
}
#endregion System Selective Lists
// ...
}
{
// ...
public override void PreProcessDatabaseUpdate(Version previousVersion, UBIKEnvironment environment)
{
base.PreProcessDatabaseUpdate(previousVersion, environment);
// This code will be executed whenever the system is upgraded,
// before a schema upgrade for this SystemDefinitions package
}
{
base.PostProcessDatabaseUpdate(previousVersion, environment);
// This code will be executed whenever the system is upgraded,
// after a schema upgrade and before content initialization and upgrade // for this SystemDefinitions package
}
public override void InitializeSystemContent(UBIKEnvironment env)
{
base.InitializeSystemContent(env);
// This code will be executed whenever the system is initialized,
// after an optional schema upgrade and before an optional content adaptation // for this SystemDefinitions package
}
public override void UpdateSystemContent(UBIKEnvironment env)
{
base.UpdateSystemContent(env);
// This code will be executed whenever the system is upgraded,
// after all other steps for this SystemDefinitions package }
// ...
}
1,815
edits