Home Reference Source
import DATE from 'observabubble/props/Date.js'
public class | source

DATE

Extends:

PropEventsProp → DATE

The Observable DATE Class

Constructor Summary

Public Constructor
public

constructor(value: Date, options: Object)

Member Summary

Public Members
public
public

value: *

Private Members
private

_options: {...defaultOptions: Object, ...options: Object}

Method Summary

Public Methods
public

parse(value: any): Date

Parses the Date

Inherited Summary

From class PropEvents
public
public
public

parent: *

private

_event: {}

public

off(eventName: Event, callback: Function)

Unbinds an event listener

public

on(eventName: Event, callback: Function)

Bind an event listener

private

_bubble(eventName: Event, target: Prop)

Calls event bubbling on the parent Observable

private

async _processEvent(eventName: Event, target: Prop, additional: Object)

Calls the listeners for the Event triggered

From class Prop
public static

isProp: *

public

name: *

public

value: *

public

[Symbol.toPrimitive](hint: *): *

public

equals(data: *): *

public

format(): *

public

get(): *

public

parse(value: *): *

public

toJSON(): *

public

toString(): *

public

valueOf(): *

private

_set(value: *, objectPattern1: {"preventEvent": *})

Public Constructors

public constructor(value: Date, options: Object) source

Override:

Prop#constructor

Params:

NameTypeAttributeDescription
value Date

The initial value of the Date

options Object
options.parent OBJECT

The Parent Object to which this Date is a member of

options.name String

The Name/key in the Parent Object to which this Date is assigned

Public Members

public [localMethod]: * source

public value: * source

Override:

Prop#value

Private Members

private _options: {...defaultOptions: Object, ...options: Object} source

Public Methods

public parse(value: any): Date source

Parses the Date

Override:

Prop#parse

Params:

NameTypeAttributeDescription
value any

The value to be parsed

Return:

Date

The parsed Date