Class DbViewUtil

java.lang.Object
com._1c.g5.v8.dt.metadata.dbview.util.DbViewUtil

public class DbViewUtil extends Object
Utility class for DBView definitions.
  • Constructor Details

    • DbViewUtil

      public DbViewUtil()
  • Method Details

    • getFields

      public static List<DbViewFieldDef> getFields(org.eclipse.emf.ecore.EObject context, DbViewFieldDef field)
      Returns fields from dbviews provided by field types or empty list.
      Parameters:
      context - the context object to figure out execution scope
      field - the DbViewFieldDef (not null).
      Returns:
      fields from dbviews provided by field types or empty list.
    • getFieldsByTypeDescription

      public static List<DbViewFieldDef> getFieldsByTypeDescription(org.eclipse.emf.ecore.EObject context, TypeDescription typeDescription)
      Returns fields provided by type description or empty list.
      Parameters:
      context - the context object to figure out execution scope
      typeDescription - the TypeDescription (may be null)
      Returns:
      fields from dbviews provided by field types or empty list.
    • getFieldsByTypeDescriptionAsMap

      public static Map<String,DbViewFieldDef> getFieldsByTypeDescriptionAsMap(org.eclipse.emf.ecore.EObject context, TypeDescription typeDescription)
      Returns fields provided by type description or empty map.
      Parameters:
      context - the context object to figure out execution scope
      typeDescription - the TypeDescription (may be null)
      Returns:
      fields from dbviews provided by field types or empty map.
    • getFieldsByType

      public static Collection<DbViewFieldDef> getFieldsByType(Type type, boolean skipTables)
      Returns fields list by type for all visible dbViews.
      Parameters:
      type - type (not null)
      skipTables - if true all tabular section fields will be filtered out
      Returns:
      fields list or empty list.
    • getObjectDefs

      public static Collection<DbViewTableDef> getObjectDefs(Type type)
    • getMainTable

      public static DbViewDef getMainTable(MdObject mdObject)
      Get Main table for MdObject
      Parameters:
      mdObject - the source metadata object, cannot be null
      Returns:
      the Main Table for given mdObject, or null if no table find
    • getAllTables

      public static List<DbViewDef> getAllTables(MdObject mdObject)
      Gets all not null db tables for given MdObject
      Parameters:
      mdObject - the source metadata object, cannot be null
      Returns:
      list of all not null DbViewDef for given mdObject, never null
    • getBasicDbViewDefs

      public static BasicDbViewDefs getBasicDbViewDefs(MdObject mdObject)
    • getMainDbViewDef

      public static DbViewTableDef getMainDbViewDef(TypeItem type)
      Returns tables list by type.
      Parameters:
      type - type (not null)
      Returns:
      tables, contained in type
    • getRlsFields

      public static List<DbViewFieldDef> getRlsFields(Object input)
      Returns object fields for rls.
      Parameters:
      input - the input object, cannot be null
      Returns:
      the list rls fields