1C:Enterprise script includes a set of standardized objects for accessing data stored in the database. They can be broken down into several types based on their purposes.
1. Manager of data structures of specific type. Examples:
Each object is a value collection, which contains managers of all the data structures of this type available in the database.
For example, the manager of catalogs (CatalogsManager) is a collection of values that contains
CatalogManager.<name> objects. Each of these objects is used to access a specific data structure manager.
2. Manager of a specific data structure. Examples:
Each object provides management tools for a specific data structure.
For example, the manager of the GoodsReceipt document (DocumentManager.GoodsReceipt) is used to find specific documents of GoodsReceipt type, create objects of such documents, and so on.
3. Object. Examples:
Such objects are used to read, edit, write, and delete data within data structures. They provide access to data structure objects and enable modifications of data in the database. They are applicable to data structures storing objects that can be referenced (CatalogObject.<name> for catalogs, DocumentObject.<name> for documents, and so on).
4. Record set. Examples:
Such objects are also used to read, edit, write, and delete data within data structures. They provide access to data structure objects and enable modifications of data in the database. They are applicable to data structures storing objects that cannot be referenced (AccumulationRegisterRecordSet.<name> for registers, RecalculationRecordSet.<name> for recalculations, and so on).
5. Reference. Examples:
Such objects are used to specify a reference to a database object and also provide a certain amount of data related to this object (DocumentRef.<name> for documents, and so on).
6. Selection. Examples:
Such objects represent data sets that contain object data selected from a single data structure according to a specific criterion (CatalogSelection.<name> for catalogs, and so on). A selection can be iterated using the Next() method. Data is read from the database dynamically, as iteration proceeds. You can get a reference to such object using the Ref property, and you can get the object itself using the GetObject method.