Property definition and class administration (IRPCPropertyDefsAdmin)
Administers property definitions and classes: reads their full definitions, adds, modifies and removes them, and starts recalculation of automatic values.
Use this interface to add, modify and remove property definitions.
| gRPC service | MFiles.IRPCPropertyDefsAdmin |
|---|---|
| Book and level | Administration API, specialized |
| Methods | 14 |
| Proto file | mfiles/IRPCPropertyDefsAdmin.proto |
Overview
This is the administrator's side of IRPCPropertyDefs. M-Files Admin and administrative tools call it; ordinary applications read property definitions and classes with the Vault API instead.
| Vault API (read side) | This service | |
|---|---|---|
| Property definitions | GetPropertyDefs: PropertyDef | GetPropertyDefsAdmin: PropertyDefAdmin, adding automatic value and validation settings and aliases |
| Classes | GetObjectClassesAndGroups | GetObjectClasses: DocClass, with workflow, name property and aliases |
| Rights | none | see below |
- Session and rights. Every method requires a vault session. Writes need the vault rights
change_metadata_structureandlicense_allows_modifications. Most reads needread_all_metadata_structure; GetObjectClasses and GetAssociatedPropertyDefs need no vault rights. Setting or changing VBScript code needs a code-execution right (see AddPropertyDef). - Property definitions: GetPropertyDefsAdmin, GetPropertyDefAdmin, AddPropertyDef, UpdatePropertyDef, RemovePropertyDef, GetLastUsedValue, IsPropertyFullTextSearchIndexable.
- Classes: GetObjectClasses, GetAssociatedPropertyDefs, AddObjectClass, ModifyObjectClass, RemoveObjectClass. Class groups are in IRPCDocClassGroupsAdmin.
- Update existing objects (server-level jobs): RecalculateProperty, UpdateObjectNames.
Metadata structure version. Adding, updating and removing a property definition increments both
property_defs_version and the vault's metadata structure version (see
GetMetadataStructureVersion); class
changes increment the metadata structure version.
The methods of this service do not send the mfiles-metadata-version-bin trailer.
See Metadata structure version and caching.
Methods
| Method | Summary | Facts |
|---|---|---|
| AddObjectClass | Creates a class with its property associations. | admin session |
| AddPropertyDef | Creates a property definition. | admin session |
| GetAssociatedPropertyDefs | Gets the properties of a class: the property definitions associated with it and whether each is required. | admin session idempotent |
| GetLastUsedValue | Gets the last number used by an automatic numbering property. | admin session idempotent |
| GetObjectClasses | Gets the administrative definitions of all classes. | admin session idempotent |
| GetPropertyDefAdmin | Gets the administrative definition of one property definition. | admin session |
| GetPropertyDefsAdmin | Gets the administrative definitions of all property definitions. | admin session idempotent |
| IsPropertyFullTextSearchIndexable | Tells whether the values of a property definition are indexed for full-text search. | admin session idempotent |
| ModifyObjectClass | Saves a changed class and, optionally, its property associations. | admin session idempotent |
| RecalculateProperty | Starts a server job that recalculates the automatic values of a property in all existing objects. | admin session |
| RemoveObjectClass | Deletes a class. | admin session |
| RemovePropertyDef | Deletes a property definition and its values from all objects, or only counts the values that would be removed. | admin session |
| UpdateObjectNames | Starts a server job that recalculates the names of all objects of a class from the class's name property. | admin session |
| UpdatePropertyDef | Saves a changed property definition. | admin session idempotent |