Sample Code Revit Batch Processor 1.1.11 documentation

Contents:

This Page

duHast.Revit.ModelHealth.Reporting.Properties package

Submodules

duHast.Revit.ModelHealth.Reporting.Properties.annotations module

Model health report functions - annotation types.

Model health report metrics can either be displayed in a family where each parameter is assigned to a metric and or data can be exported to text files which can be used to visualize key metrics over time.

duHast.Revit.ModelHealth.Reporting.Properties.annotations.get_number_of_text_types(doc)

Gets the number of text types in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of text types in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.annotations.get_number_of_unused_text_types(doc)

Gets the number of unused text types in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of unused text types in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.annotations.get_number_of_dimension_types(doc)

Gets the number of dimension types in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of dimension types in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.annotations.get_number_of_unused_dimension_types(doc)

Gets the number of unused dimension types in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of unused dimension types in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.annotations.get_number_of_arrow_head_types(doc)

Gets the number of arrow head types in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of arrow head types in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.annotations.get_number_of_unused_arrow_head_types(doc)

Gets the number of unused arrow head types in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of unused arrow head types in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.constants module

Model health constant values.

Constant values used by Model health reports.

duHast.Revit.ModelHealth.Reporting.Properties.constants.FAILED_TO_RETRIEVE_VALUE = -1

Default value if unable to retrieve a health metric value from model

duHast.Revit.ModelHealth.Reporting.Properties.constants.MODEL_HEALTH_TRACKER_FAMILY = 'Symbol_GraphicModelHealth_ANN'

A revit family displaying the health metrics retrieved by this code.

duHast.Revit.ModelHealth.Reporting.Properties.design_set_options module

Model health report functions - design set and options.

Model health report metrics can either be displayed in a family where each parameter is assigned to a metric and or data can be exported to text files which can be used to visualize key metrics over time.

duHast.Revit.ModelHealth.Reporting.Properties.design_set_options.get_number_of_design_sets(doc)

Gets the number of design sets in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of design sets in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.design_set_options.get_number_of_design_options(doc)

Gets the number of design options in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of design option in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.detail_items module

Model health report functions - detail items.

Model health report metrics can either be displayed in a family where each parameter is assigned to a metric and or data can be exported to text files which can be used to visualize key metrics over time.

duHast.Revit.ModelHealth.Reporting.Properties.detail_items.get_number_of_filled_regions(doc)

Gets the number of filled region instances in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of filled region instances in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.families module

Model health report functions - families.

Model health report metrics can either be displayed in a family where each parameter is assigned to a metric and or data can be exported to text files which can be used to visualize key metrics over time.

duHast.Revit.ModelHealth.Reporting.Properties.families.get_number_of_families(doc)

Gets the number of families loaded into the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of families loaded into model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.families.get_number_of_in_place_families(doc)

Gets the number of in-place families the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of in-place in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.general module

Model health report functions - general reports.

Model health report metrics can either be displayed in a family where each parameter is assigned to a metric and or data can be exported to text files which can be used to visualize key metrics over time.

duHast.Revit.ModelHealth.Reporting.Properties.general.get_current_date(doc)

Get the current date

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

The current date in format YYYY_MM_DD.

Return type:

str

duHast.Revit.ModelHealth.Reporting.Properties.general.get_workset_number(doc)

Gets the number of worksets in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

The number of worksets in a model.

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.general.get_current_file_size(doc)

Gets the file size in MB.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

File size in MB. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.general.get_number_of_warnings(doc)

Gets the number of warnings in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of warnings in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.groups module

Model health report functions - groupes.

Model health report metrics can either be displayed in a family where each parameter is assigned to a metric and or data can be exported to text files which can be used to visualize key metrics over time.

duHast.Revit.ModelHealth.Reporting.Properties.groups.get_number_of_detail_groups(doc)

Gets the number of detail group definitions the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of detail group definitions in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.groups.get_number_of_model_groups(doc)

Gets the number of model group definitions in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of model group definitions in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.groups.get_number_of_unplaced_detail_groups(doc)

Gets the number of unplaced detail group definitions in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of unplaced detail group definitions in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.groups.get_number_of_unplaced_model_groups(doc)

Gets the number of unplaced model group definitions in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of unplaced model group definitions in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.line_styles_types module

Model health report functions - line styles and types.

Model health report metrics can either be displayed in a family where each parameter is assigned to a metric and or data can be exported to text files which can be used to visualize key metrics over time.

duHast.Revit.ModelHealth.Reporting.Properties.line_styles_types.get_number_of_line_styles(doc)

Gets the number of line styles in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of line styles in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.line_styles_types.get_number_of_line_patterns(doc)

Gets the number of line patterns in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of line patterns in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.line_styles_types.get_number_of_fill_patterns(doc)

Gets the number of fill pattern in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of fill pattern in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.rooms module

Model health report functions - rooms.

Model health report metrics can either be displayed in a family where each parameter is assigned to a metric and or data can be exported to text files which can be used to visualize key metrics over time.

duHast.Revit.ModelHealth.Reporting.Properties.rooms.get_number_of_rooms(doc)

Gets the number of rooms in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of rooms in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.rooms.get_number_of_unplaced_rooms(doc)

Gets the number of unplaced rooms in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of unplaced rooms in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.rooms.get_number_of_redundant_rooms(doc)

Gets the number of redundant rooms in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of redundant rooms in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.rooms.get_number_of_not_enclosed_rooms(doc)

Gets the not enclosed number of rooms in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of not enclosed rooms in the model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.view module

Model health report functions - views.

Model health report metrics can either be displayed in a family where each parameter is assigned to a metric and or data can be exported to text files which can be used to visualize key metrics over time.

duHast.Revit.ModelHealth.Reporting.Properties.view.get_number_of_sheets(doc)

Gets the number of sheets in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of sheets in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.view.get_number_of_views(doc)

Gets the number of views in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of views in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.view.get_number_of_unplaced_views(doc)

Gets the number of unplaced views in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of unplaced views in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.view.get_number_of_view_templates(doc)

Gets the number of view templates in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of view templates in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.view.get_number_of_unused_view_templates(doc)

Gets the number of unplaced view templates in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of unplaced view templates in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.view.get_number_of_view_filters(doc)

Gets the number of view filters in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of number of view filters in model. On exception it will return -1

Return type:

int

duHast.Revit.ModelHealth.Reporting.Properties.view.get_number_of_unused_view_filters(doc)

Gets the number of unused view filters in the model.

Parameters:

doc (Autodesk.Revit.DB.Document) – Current Revit model document.

Returns:

Number of unused view filters in model. On exception it will return -1

Return type:

int

Module contents