Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ValidationService

Hierarchy

  • ValidationService

Index

Constructors

constructor

Properties

core

core: any

currentValidation

currentValidation: default

errorHandler

errorHandler: ValidationErrorMapper

observer

observer: BubblingCollectionObservable = ...

schema

schema: JSONSchema

store

store: default

watcher

watcher: any[] = ...

list of active watchers on update-lifecycle events

Methods

destroy

  • destroy(): void

get

getErrors

  • getErrors(pointer?: string, withChildErrors?: boolean): ValidationError[]

getErrorsAndWarnings

  • getErrorsAndWarnings(pointer?: string, withChildErrors?: boolean): ValidationError[]

getWarnings

  • getWarnings(pointer?: string, withChildWarnings?: boolean): ValidationError[]

notify

notifyWatcher

  • notifyWatcher(event: ValidationDoneEvent): void

observe

  • observe(pointer: string, observer: Observer, bubbledEvents?: boolean): Observer

removeObserver

set

setErrorHandler

  • setErrorHandler(callback: ValidationErrorMapper): void

unwatch

  • unwatch(callback: Watcher): Watcher

validate

  • Starts the validation, executing callback handlers and emitters on the go

    Parameters

    • data: any

      data to validate

    • pointer: string = "#"

    Returns Promise<ValidationError[]>

    promise, resolving with list of errors when all async validations are performed

watch

  • watch(callback: Watcher): Watcher

Generated using TypeDoc