Gamalto

Fork me on GitHub

Object Shape Overview

Gamalto. Shape

new Gamalto.Shape(x, y)

Abstract object to create a geometric shape.

Parameters
Name Type Description
x number

Horizontal position of the shape origin.

y number

Vertical position of the shape origin.

Extends

Members

origin :Gamalto.IPoint

Gets of sets the origin of the shape.

tag :object

inherited

Utility property to exchange data between objects.

Inherited From

Methods

clone() object

inherited abstract

Clones the object. It will be shallow copy unless otherwise specfied.

Inherited From
Returns
  • New instance of the object. Defaults to null.

pointInShape(x, y) boolean

abstract

Abstract method to determine if a point lies inside the shape.

Parameters
Name Type Description
x number

Horizontal position of the point to test.

y number

Vertical position of the point to test.

Returns
  • True if the point lies inside the shape.

toBox() Gamalto.Box

abstract

Abstract method to get the bounding box of the shape.

Returns
  • Bounding box of the shape.

toString() string

inherited abstract

Converts the object into a string.

Inherited From
Returns
  • string

translate(vec)

abstract

Translates the shape by the vector.

Parameters
Name Type Description
vec Gamalto.IPoint

Vector to use for the translation.

Documentation generated by JSDoc 3.3.2 on Sun Sep 13 2015 20:13:31 GMT+0200 (CEST)