peculiarities of generation and properties of edit forms, operations, attributes, and methods edit form

The edit form provides a user interface for entering/editing the instance of the data object in one or multiple views. To describe the editing form, you must create a UML class with the stereotype editform. For example:

the edit form Generation

  • Class UI-independent edit form that are inherited from ICSSoft.STORMNET.UI.BaseIndpdEdit.
  • .Net-dependent interface for editing form.
  • UI-related form editable (if necessary).
  • Attributes of the form are generated in the following way:
  • If you have enabled the generation of UI-dependent forms, is generated .Net-UI interface-dependent forms editing definition properties, but only if this attribute is public.
  • Code UI-specific form is generated which implements the above interface definition of virtual properties, as well as private member and both accessors code for setting/getting the value of a private member, followed by parentheses programmer.
  • Code UI-independent forms generated definition of virtual property with the specified modifier. If the generation of the UI-dependent form is included in generated code properties the same properties of the UI-dependent forms through the interface.
  • Methods of the form are generated in the following way:
  • If you have enabled the generation of UI-dependent forms, is generated .Net-UI interface-dependent form editing method definition, but only if this method is public.
  • Code UI-specific form is generated that implements the above interface definition of the virtual method, and in this parenthesis the programmer (similar as described in article class Methods and method parameters.
  • Code UI-independent form is generated by defining a virtual method with the specified modifier. If the generation of the UI-dependent forms included in the code generated method call the same method the UI-dependent forms through the interface.

Additional editable properties and how that is generated

Most importantly, editable in the advanced properties, select a class and view in which you want to edit an object of that class. This is the tab Составные представления:

You can specify only one class and one view in which to edit the object in this form. If you specify multiple classes and/or performances, all but the first are ignored. To choose a class and performance, you should click ...:

Bookmark Форма:

Name - Name .Net class independent of the form and its derivative for the dependent, for example:

winform[Name]

Description - a description of the class. DocComment before the class definition an independent Caption - a user name (shown in UI). The caption on the form. GenerateDependedForm. If the option is set, - generated UI-dependent (WinForm) form the user interface in the source code that allows вручную to place on the form controls. If the option is not installed, use the generic UI-independent edit form where control elements corresponding to the attributes in the view are automatically. FixDependedForm. If the option is set, - UI-dependent (WinForm) form not pregenerated. This is done to make sure that are made in the form of changes in the composition and arrangement of the controls will not be lost, which sometimes occurs due to the presence of errors in the environment Visual Studio .Net. If the box is not ticked, the generation is as follows:

  • If the view (the name and message attributes) are not changed, then pregenerated nonvisual part of the form (methods, properties, etc.).
  • If completely changed this view (its name, i.e. after the last generation otherwise the view), the visual part pregenerated completely, all controls are removed and placed new ones in accordance with the new view.
  • If you have changed message attributes view, on the form, added controls, added to the corresponding view attributes. Elementary management relevant remote attributes is not destroyed on the form.

Packet, NamespacePostfix - allow to set the Assembly and namespace. Cm. article assemblies Location after code generation. PBCustomAttributes - allows you to specify whether to brace the programmer immediately before the description of the class for ручного of any attributes. If the option is specified - generated bracket programmer for ручного making .Net attributes to class-independent form. PBMembers. If the option is specified - generated bracket programmer for ручного of any of the members of the class of independent form. PropertyLookup. Allows for a separate form to configure which list form to open this form to select the appropriate related objects (masters). Is generated in the method code GetEditor UI-independent edit form which returns the list type of the form based on behalf of artisan properties.

At the top of the list are the artisans of the properties in the lower drop-down list, select the form that needs to open for selection by the user respectively. the linked object. EditFormOperations - setting is available in the form of a transaction.

.

Allows you to specify which operations are available on this form (respectively, which buttons appear on the control panel):

  • Save - save
  • Save and Close - save followed by closing the form
  • Print - печать; * Print preview - preview

Generated:

  • If you use a generic form (tick GenerateDependedForm not set), the generated parameter in the constructor of the dependent form in the method GetDpdForm() independent
  • If you are using the generated form is generated directly in dependent form by setting the visibility of the toolbar buttons PrintContainer is the class name with the stereotype printform, which is a printed form that is used when printing with forms editing. In code independent form is generated GetPrinter method overloading, in which:
  • If PrintContainer is not specified, an error is returned NoSuchContainerException
  • If PrintContainer specified, returns the type of the container

In this method, before the return value is unmuted bracket of the programmer, which can be encoded вручную the return type in the case of logic, which, for example, returns printed form depending on the properties of the object. ScriptName - the script name to use this form. Matches the name of the EBSD-maps used to describe the scenario. PstrfGetScript method in class independent is overloaded so that it returns from the provider scenarios scenario with the specified name. PublishToEBSD. If the option is specified before the class-independent form is generated to specify a PublishToEBSDAttribute` attribute that specifies the availability of this class to use the chart editor scripts.

attribute Properties

The properties of the attributes are the same specified in article Attributes data classes, taking into account the above comments.

Properties methods

Properties methods similar to those described in article class Methods and method parameters, taking into account the above comments.

Переведено сервисом «Яндекс.Переводчик» http://translate.yandex.ru