Static _baseStatic Protected _decompStatic Protected _nextStatic Protected _nowStatic Protected _seedStatic Protected _warnedStatic logThe console logging level to use, where each level includes all levels above and excludes the levels below. The default level is 'debug' which shows all console messages.
Static Protected _seededStatic Protected _topologicalStatic chainTakes n functions as arguments and returns a new function that calls them in order.
The arguments applied when calling the new function will also be applied to every function passed.
The value of this refers to the last value returned in the chain that was not undefined.
Therefore if a passed function does not return a value, the previously returned value is maintained.
After all passed functions have been called the new function returns the last returned value (if any).
If any of the passed functions are a chain, then the chain will be flattened.
Rest ...params: Function[]The functions to chain.
A new function that calls the passed functions in order.
Static chainChains a function to excute after the original function on the given path relative to base.
See also docs for Common.chain.
The base object
The path relative to base
The function to chain after the original
The chained function that replaced the original
Static chainChains a function to excute before the original function on the given path relative to base.
See also docs for Common.chain.
The base object
The path relative to base
The function to chain before the original
The chained function that replaced the original
Static chooseStatic clampStatic cloneCreates a new clone of the object, if deep is true references will also be cloned.
Optional deep: booleanobj cloned
Static colorStatic deprecatedShows a deprecated console warning when the function on the given object is called. The target function will be replaced with a new function that first shows the warning and then calls the original function.
The object or module
The one-time message to show if the function is called
Static extendExtends the object in the first argument using the object in the second argument.
Optional deep: boolean | ERest ...params: E[]obj extended
Optional deep: boolean | TRest ...params: T[]Optional deep: boolean | DeepPartial<T>Rest ...params: DeepPartial<T>[]Static getGets a value from base relative to the path string.
The base object
The path relative to base, e.g. 'Foo.Bar.baz'
Optional begin: numberPath slice begin
Optional end: numberPath slice end
The object at the given path
Static getReturns the poly-decomp library module provided through Common.setDecomp,
otherwise returns the global decomp if set.
The poly-decomp library module if provided.
Static infoStatic isStatic isStatic isReturns true if the object is an Object.
True if the object is an Object, otherwise false
isObject
Static keysReturns the list of keys for the given object.
keys
keys
Static logStatic nextStatic nowStatic randomStatic setSets a value on base relative to the given path string.
The base object
The path relative to base, e.g. 'Foo.Bar.baz'
The value to set
Optional begin: numberPath slice begin
Optional end: numberPath slice end
Pass through val for chaining
Static setProvide the poly-decomp library module to enable
concave vertex decomposition support when using Bodies.fromVertices e.g. Common.setDecomp(require('poly-decomp')).
The poly-decomp library module.
Static shuffleStatic signStatic topologicalTakes a directed graph and returns the partially ordered set of vertices in topological order. Circular dependencies are allowed.
Partially ordered set of vertices in topological order.
Static valuesReturns the list of values for the given object.
Array of the objects property values
values
Static warnStatic warnGenerated using TypeDoc
The
Matter.Commonmodule contains utility functions that are common to all modules.