APIs

Show:

Constructor

Shape

(
  • options
)

Parameters:

  • options Object
    • [name= my shape] String optional
    • [shapeType] EnumShapeType optional
    • [color= 300] EnumColor optional
    • [inner_color= 200] EnumColor optional

Methods

binaryStoreSize

() Number

Calculate the required size to store this object in a binary stream.

Returns:

Number:

decode

(
  • stream
  • [option]
)

decode the object from a binary stream

Parameters:

encode

(
  • stream
)

encode the object into a binary stream

Parameters:

isValid

() Boolean

verify that all object attributes values are valid according to schema

Returns:

Boolean:

toString

() String

Returns:

String:

Properties

inner_color

EnumColor

Default: function () { return Color.BLUE; }

name

String

Default: function () { return "my shape"; }