C# Class Revit.SDK.Samples.GridCreation.CS.Validation

Class to validate input data before creating grids
Afficher le fichier Open project: AMEE/revit

Méthodes publiques

Méthode Description
ShowWarningMessage ( String message, String caption ) : void

Show a warning message box

ValidateCoord ( Control coordCtrl ) : bool

Validate coordinate value

ValidateDegree ( Control degreeCtrl ) : bool

Validate degree value

ValidateDegrees ( Control startDegree, Control endDegree ) : bool

Validate start degree and end degree

ValidateLabel ( Control labelCtrl, ArrayList allLabels ) : bool

Validate label

ValidateLabels ( Control label1Ctrl, Control label2Ctrl ) : bool

Assure two labels are not same

ValidateLength ( Control lengthCtrl, String typeName, bool canBeZero ) : bool

Validate length value

ValidateNotNull ( Control control, String typeName ) : bool

Assure value is not null

ValidateNumber ( Control numberCtrl ) : bool

Validate number value

ValidateNumbers ( Control number1Ctrl, Control number2Ctrl ) : bool

Validate numbers in UI

Method Details

ShowWarningMessage() public static méthode

Show a warning message box
public static ShowWarningMessage ( String message, String caption ) : void
message String Message
caption String title of message box
Résultat void

ValidateCoord() public static méthode

Validate coordinate value
public static ValidateCoord ( Control coordCtrl ) : bool
coordCtrl System.Windows.Forms.Control Control contains coordinate information
Résultat bool

ValidateDegree() public static méthode

Validate degree value
public static ValidateDegree ( Control degreeCtrl ) : bool
degreeCtrl System.Windows.Forms.Control Control contains degree information
Résultat bool

ValidateDegrees() public static méthode

Validate start degree and end degree
public static ValidateDegrees ( Control startDegree, Control endDegree ) : bool
startDegree System.Windows.Forms.Control Control contains start degree information
endDegree System.Windows.Forms.Control Control contains end degree information
Résultat bool

ValidateLabel() public static méthode

Validate label
public static ValidateLabel ( Control labelCtrl, ArrayList allLabels ) : bool
labelCtrl System.Windows.Forms.Control Control contains label information
allLabels System.Collections.ArrayList List contains all labels in Revit document
Résultat bool

ValidateLabels() public static méthode

Assure two labels are not same
public static ValidateLabels ( Control label1Ctrl, Control label2Ctrl ) : bool
label1Ctrl System.Windows.Forms.Control Control contains label information
label2Ctrl System.Windows.Forms.Control Control contains label information
Résultat bool

ValidateLength() public static méthode

Validate length value
public static ValidateLength ( Control lengthCtrl, String typeName, bool canBeZero ) : bool
lengthCtrl System.Windows.Forms.Control Control contains length information
typeName String Type of length
canBeZero bool Whether the length can be zero
Résultat bool

ValidateNotNull() public static méthode

Assure value is not null
public static ValidateNotNull ( Control control, String typeName ) : bool
control System.Windows.Forms.Control Control contains information needs to be checked
typeName String Type of information
Résultat bool

ValidateNumber() public static méthode

Validate number value
public static ValidateNumber ( Control numberCtrl ) : bool
numberCtrl System.Windows.Forms.Control Control contains number information
Résultat bool

ValidateNumbers() public static méthode

Validate numbers in UI
public static ValidateNumbers ( Control number1Ctrl, Control number2Ctrl ) : bool
number1Ctrl System.Windows.Forms.Control Control contains number information
number2Ctrl System.Windows.Forms.Control Control contains another number information
Résultat bool