Options
All
  • Public
  • Public/Protected
  • All
Menu

Resource allocation information for a certain tick.

Hierarchy

  • BaseAllocationInterval
    • ResourceAllocationInterval

Index

Properties

assignments

assignments: Set<SchedulerProAssignmentMixin> = null

Resource assignments ingoing in the interval.

effort

effort: number = 0

Effort in the interval in milliseconds.

inEventTimeSpan

inEventTimeSpan: boolean = false

Indicates if the interval is in the middle of the event timespan.

isOverallocated

isOverallocated: boolean = false

Indicates that the resource (or the assignment if the interval represents the one) is over-allocated in the interval. So true when effort is more than possible maximum.

isUnderallocated

isUnderallocated: boolean = false

Indicates that the resource (or assignment if the interval represents the one) is under-allocated in the interval. So true when effort is less than possible maximum.

maxEffort

maxEffort: number = 0

Maximum possible effort in the interval in milliseconds.

resource

The allocated resource.

tick

Tick (time interval) the allocation is collected for.

units

units: number = 0

Utilization level of the resource (or the assignment if the interval represents the one) in percent.

Methods

initialize

  • initialize<T>(props?: Partial<T>): void
  • This method applies its 1st argument (if any) to the current instance using Object.assign().

    Supposed to be overridden in the subclasses to customize the instance creation process.

    Type parameters

    Parameters

    • Optional props: Partial<T>

    Returns void

Static new

  • new<T>(this: T, props?: Partial<InstanceType<T>>): InstanceType<T>
  • This is a type-safe static constructor method, accepting a single argument, with the object, corresponding to the class properties. It will generate a compilation error, if unknown property is provided.

    For example:

    class MyClass extends Base {
        prop     : string
    }
    
    const instance : MyClass = MyClass.new({ prop : 'prop', wrong : 11 })

    will produce:

    TS2345: Argument of type '{ prop: string; wrong: number; }' is not assignable to parameter of type 'Partial<MyClass>'.
    Object literal may only specify known properties, and 'wrong' does not exist in type 'Partial<MyClass>'

    The only thing this constructor does is create an instance and call the initialize method on it, forwarding the first argument. The customization of instance is supposed to be performed in that method.

    Type parameters

    Parameters

    • this: T
    • Optional props: Partial<InstanceType<T>>

    Returns InstanceType<T>

Generated using TypeDoc