@crestron/ch5-shell-utilities-cli
Version:
CH5 Shell Utilities CLI for command scripts
161 lines (160 loc) • 4.68 kB
TypeScript
import { Ch5BaseClassForCli } from "../Ch5BaseClassForCli";
import { ICh5Cli } from "../ICh5Cli";
export declare class Ch5ValidateProjectConfigCli extends Ch5BaseClassForCli implements ICh5Cli {
showOutputMessages: boolean;
exitProcess: boolean;
private errorsFound;
private warningsFound;
private projectConfigJson;
private projectConfigJsonSchema;
static RULES: any;
constructor(showOutputMessages?: boolean, exitProcess?: boolean);
/**
* Method for validating project-config.json file
*/
run(): Promise<boolean>;
printOutputErrorsAndWarnings(errors: any[], warnings: any[]): void;
/**
* Validating the schema file
*/
private validateSchema;
/**
* Check if the pages defined in project-config.json exists in project
*/
private verifyPagesExist;
/**
* Check if the widgets defined in project-config.json exists in project
*/
private verifyWidgetsExist;
/**
* Check if the selected theme is not empty and available in the list of themes
*/
private checkInvalidSelectedTheme;
private verifyPageFolderPath;
private verifyWidgetFolderPath;
private verifyPageNameWithFileNames;
private verifyWidgetNameWithFileNames;
/**
* Check if any other folders exist in the app which are not defined in project-config.json
*/
private checkIfPagesAreRepeated;
/**
* Check if any other folders exist in the app which are not defined in project-config.json
*/
private checkIfWidgetsAreRepeated;
/**
* Check if any other folders exist in the app which are not defined in project-config.json
*/
private checkPageSequence;
/**
* Checks if the theme name is repeated in the themes array.
* @param {*} pagesArray
*/
private checkIfThemeNamesAreRepeated;
/**
* If menuOrientation is either veritcal or horizontal , then check if atleast 1 navigation item exists in the list
*/
private checkAtleastOneNavigationForMenu;
/**
* Warning for iconPosition for vertical menu orientation
* @param {*} pagesArray
* @param {*} menuOrientation
*/
private checkIconPositionForVerticalMenu;
/**
* Check if forceDeviceXPanel is set to false for zoom project
* @param forceDeviceXPanel
* @param projectType
*/
private checkIfForceDeviceXPanelForZoomRoomControl;
/**
* Check menuOrientation="vertical" and header display="false"
* @param {*} pagesArray
* @param {*} menuOrientation
*/
private checkHeaderAvailabilityForVerticalMenu;
/**
* Check if the header component has navigation
* @param {*} projectConfigObject
* @param {*} pagesArray
* @param {*} headerDisplay
* @param {*} menuOrientation
*/
private checkIfHeaderComponentsHaveNavigation;
/**
* Check if the footer component has navigation
* @param {*} projectConfigObject
* @param {*} pagesArray
* @param {*} footerDisplay
* @param {*} menuOrientation
*/
private checkIfFooterComponentsHaveNavigation;
/**
* Pages array is empty
* @param {*} pagesArray
*/
private checkIfNoPagesExist;
/**
* Page and Widget Names collide
* @param {*} pagesArray
* @param {*} widgetsArray
*/
private checkIfPagesAndWidgetNamesDuplicate;
/**
* Check if default view is valid
* @param {*} pagesArray
*/
private checkIfDefaultViewIsValid;
/**
* Check if any other folders exist in the app which are not defined in project-config.json
*/
private checkIfUnwantedFilesAndFoldersExist;
/**
*
* @param {*} objectArray
* @param {*} filePath
*/
private checkIfFileExists;
/**
*
* @param {*} objectArray
* @param {*} folderPath
*/
private checkIfFolderExists;
/**
* Returns errors found
*/
getErrors(): any;
/**
* Clears the errors array
*/
private clearErrors;
/**
* Adds error message to the array
* @param {string} heading
* @param {string} message
* @param {string} resolution
*/
private addError;
/**
* Returns warnings found
*/
getWarnings(): any;
/**
* Clears the warning array
*/
private clearWarnings;
/**
* Adds warning message to the array
* @param {string} heading
* @param {string} message
* @param {string} resolution
*/
private addWarning;
/**
* Composes the output message for errors
* @param {array} dataArray
* @param {string} type
*/
private composeOutput;
}