@@ -57,13 +57,7 @@ export function isObject(value: any): boolean;
5757 * @returns {boolean } True if `value` is an `Object` with a null prototype
5858 */
5959export function isBlankObject ( value : any ) : boolean ;
60- /**
61- * Determines if a reference is a `String`.
62- *
63- * @param {* } value Reference to check.
64- * @returns {boolean } True if `value` is a `String`.
65- */
66- export function isString ( value : any ) : boolean ;
60+ export function isString ( value : unknown ) : boolean ;
6761/**
6862 * Determines if a reference is a null.
6963 *
@@ -78,6 +72,13 @@ export function isNull(value: any): boolean;
7872 * @returns {boolean } True if `value` is null or undefined.
7973 */
8074export function isNullOrUndefined ( obj : any ) : boolean ;
75+ /**
76+ * Determines if a reference is not null or undefined.
77+ *
78+ * @param {* } obj Reference to check.
79+ * @returns {boolean } True if `value` is null or undefined.
80+ */
81+ export function notNullOrUndefined ( obj : any ) : boolean ;
8182/**
8283 * Determines if a reference is a `Number`.
8384 *
@@ -434,9 +435,30 @@ export function shallowCopy(src: any, dst: any): any;
434435 */
435436export function assert ( argument : boolean , errorMsg ?: string ) : void ;
436437/**
437- * Throw error if the argument is falsy.
438+ * Validate a value using a predicate function.
439+ * Throws if the predicate returns false.
440+ *
441+ * @param {ng.Validator } fn - Predicate validator function.
442+ * @param {* } arg - The value to validate.
443+ * @param {string } name - Parameter name (included in error message).
444+ * @returns {* } The validated value.
445+ * @throws {TypeError } If the value does not satisfy the validator.
446+ */
447+ export function validate ( fn : ng . Validator , arg : any , name : string ) : any ;
448+ /**
449+ * @param {* } arg - The value to validate.
450+ * @param {string } name - Parameter name (included in error message).
451+ * @returns {* } The validated value.
452+ * @throws {TypeError } If the value does not satisfy the validator.
453+ */
454+ export function validateRequired ( arg : any , name : string ) : any ;
455+ /**
456+ * @param {* } arg - The value to validate.
457+ * @param {string } name - Parameter name (included in error message).
458+ * @returns {* } The validated value.
459+ * @throws {TypeError } If the value does not satisfy the validator.
438460 */
439- export function validate ( fn : any , arg : any , name : any ) : any ;
461+ export function validateArray ( arg : any , name : string ) : any ;
440462/**
441463 * Throw error if the argument is falsy.
442464 */
@@ -452,12 +474,12 @@ export function assertArgFn(
452474 *
453475 * Omitted or undefined options will leave the corresponding configuration values unchanged.
454476 *
455- * @param {import("./interface.ts") .ErrorHandlingConfig } [config]
456- * @returns {import("./interface.ts") .ErrorHandlingConfig }
477+ * @param {ng .ErrorHandlingConfig } [config]
478+ * @returns {ng .ErrorHandlingConfig }
457479 */
458480export function errorHandlingConfig (
459- config ?: import ( "./interface.ts" ) . ErrorHandlingConfig ,
460- ) : import ( "./interface.ts" ) . ErrorHandlingConfig ;
481+ config ?: ng . ErrorHandlingConfig ,
482+ ) : ng . ErrorHandlingConfig ;
461483/**
462484 * This object provides a utility for producing rich Error messages within
463485 * AngularTS. It can be called as follows:
0 commit comments