private void MarkIndexedField(PersistenceContext context, string className, string
                                      fieldName, bool indexed)
        {
            CustomField field = CustomClass(context, className).CustomField(fieldName);

            field.Indexed(indexed);
            UpdateMetadata(context, field);
            Restart(context);
        }
        private void ConfigureFields(IConfiguration config, CustomClass cc)
        {
            IEnumerator fields = cc.CustomFields();

            while (fields.MoveNext())
            {
                CustomField field = (CustomField)fields.Current;
                config.ObjectClass(cc).ObjectField(field.GetName()).Indexed(field.Indexed());
            }
        }