IgeObject

Method: category

Gets / sets the arbitrary category name that the object belongs to.
category (String val)
  • Stringval
Returns *

Get the category of an entity

var entity = new IgeEntity();
console.log(entity.category());

Set the category of an entity

var entity = new IgeEntity();
entity.category('myNewCategory');

Set the category of an entity via chaining

var entity = new IgeEntity()
    .category('myNewCategory');

Get all the entities belonging to a category

var entityArray = ige.$$('categoryName');

Remove the category of an entity

// Set category to some name
var entity = new IgeEntity()
    .category('myCategory');

// Will output "myCategory"
console.log(entity.category());

// Now remove the category
entity.category('');

// Will return ""
console.log(entity.category());
© Copyright 2013 Irrelon Software Limited. All Rights Reserved. UK Registered Company Number: 07522767
Isogenic (ī´sōjen´ik): Adj originating from a common source; possessing the same genetic composition.
Strange Things Happen at the One Two Point