Packagecom.flexcalendar.components.calendar.utils
Classpublic class ItemsBlock
InheritanceItemsBlock Inheritance Object

Class describing single block of items, it means items that are overlapping in day/multiday view.



Public Properties
 PropertyDefined By
  end : Date
End time
ItemsBlock
  itemsDetails : Array
Array of items
ItemsBlock
  minimumItemTime : Number
Minimum item duration, in mills.
ItemsBlock
  positions : Array
Array of positions
ItemsBlock
  requiredSlots : int
[read-only] Return number of required slots.
ItemsBlock
  sizes : Array
Array of sizes
ItemsBlock
  start : Date
Start time
ItemsBlock
Protected Properties
 PropertyDefined By
  spaceReservation : SpaceReservation
SpaceReservation object - performs calculations of the required positions
ItemsBlock
Public Methods
 MethodDefined By
  
ItemsBlock(start:Date, end:Date, minimumItemTime:Number, itemDetails:ItemDetails = null)
Create new block instance
ItemsBlock
  
add(itemDetails:ItemDetails):void
Add new item to this block
ItemsBlock
  
Perform position calculations
ItemsBlock
Property Detail
endproperty
public var end:Date

End time

itemsDetailsproperty 
public var itemsDetails:Array

Array of items

minimumItemTimeproperty 
public var minimumItemTime:Number

Minimum item duration, in mills. Should be computed from minimum calendar item renderer height.

positionsproperty 
public var positions:Array

Array of positions

requiredSlotsproperty 
requiredSlots:int  [read-only]

Return number of required slots.


Implementation
    public function get requiredSlots():int
sizesproperty 
public var sizes:Array

Array of sizes

spaceReservationproperty 
protected var spaceReservation:SpaceReservation

SpaceReservation object - performs calculations of the required positions

startproperty 
public var start:Date

Start time

Constructor Detail
ItemsBlock()Constructor
public function ItemsBlock(start:Date, end:Date, minimumItemTime:Number, itemDetails:ItemDetails = null)

Create new block instance

Parameters
start:Date — Start time of the block
 
end:Date — Initial end time of the block
 
minimumItemTime:Number
 
itemDetails:ItemDetails (default = null)
Method Detail
add()method
public function add(itemDetails:ItemDetails):void

Add new item to this block

Parameters

itemDetails:ItemDetails — ItemDetails object

calculatePositionsAndSizes()method 
public function calculatePositionsAndSizes():void

Perform position calculations