import * as NullOrUndefinedCheck from "../../../../sync/check/generic/null-or-undefined"; import * as check from "../../../../sync/check/array-like"; export type MaybeArrayLikeErrorCodeType = check.ArrayLikeErrorCodeType; export function checkMaybeArrayLike (mixed : any) : undefined|MaybeArrayLikeErrorCodeType { return NullOrUndefinedCheck.checkNullOrUndefinedOr( mixed, check.checkArrayLike ); } export type MaybeMinLengthErrorCodeType = check.MinLengthErrorCodeType; export function checkMaybeMinLength (mixed : any, min : number) : undefined|MaybeMinLengthErrorCodeType { return NullOrUndefinedCheck.checkNullOrUndefinedOr( mixed, () => { return check.checkMinLength(mixed, min) } ); } export type MaybeMaxLengthErrorCodeType = check.MaxLengthErrorCodeType; export function checkMaybeMaxLength (mixed : any, max : number) : undefined|MaybeMaxLengthErrorCodeType { return NullOrUndefinedCheck.checkNullOrUndefinedOr( mixed, () => { return check.checkMaxLength(mixed, max) } ); } export type MaybeLengthErrorCodeType = check.LengthErrorCodeType; export function checkMaybeLength (mixed : any, args : { min? : number, max? : number }) : undefined|MaybeLengthErrorCodeType { return NullOrUndefinedCheck.checkNullOrUndefinedOr( mixed, () => { return check.checkLength(mixed, args) } ); } export type MaybeNonEmptyErrorCodeType = check.NonEmptyErrorCodeType; export function checkMaybeNonEmpty (mixed : any) : undefined|MaybeNonEmptyErrorCodeType { return NullOrUndefinedCheck.checkNullOrUndefinedOr( mixed, check.checkNonEmpty ); } export type MaybeContainsErrorCodeType = check.ContainsErrorCodeType; export function checkMaybeContains (mixed : any, x : any) : undefined|MaybeContainsErrorCodeType { return NullOrUndefinedCheck.checkNullOrUndefinedOr( mixed, () => { return check.checkContains(mixed, x) } ); } export type MaybeNoDuplicateErrorCodeType = check.NoDuplicateErrorCodeType; export function checkMaybeNoDuplicate (mixed : any) : undefined|MaybeNoDuplicateErrorCodeType { return NullOrUndefinedCheck.checkNullOrUndefinedOr( mixed, check.checkNoDuplicate ); }